diff options
author | stolz <unknown> | 2004-11-12 17:08:58 +0000 |
---|---|---|
committer | stolz <unknown> | 2004-11-12 17:08:58 +0000 |
commit | c2bb98f417b0f04d54a050947a7624235ca59ef9 (patch) | |
tree | 99bc92575fd97083beb1adbefee333d48211e009 /System/Posix | |
parent | ff439442a6eba116a3735535cabd51d7f4899837 (diff) |
[project @ 2004-11-12 17:08:58 by stolz]
Fix FFI-funniness, cf.
http://www.haskell.org/pipermail/glasgow-haskell-users/2002-February/003020.html
Noticed by: George Russell (again)
Diffstat (limited to 'System/Posix')
-rw-r--r-- | System/Posix/Env.hsc | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/System/Posix/Env.hsc b/System/Posix/Env.hsc index 1c85805..f1ec317 100644 --- a/System/Posix/Env.hsc +++ b/System/Posix/Env.hsc @@ -55,12 +55,11 @@ foreign import ccall unsafe "getenv" getEnvironmentPrim :: IO [String] getEnvironmentPrim = do - c_environ <- peek c_environ_p - arr <- peekArray0 nullPtr c_environ + arr <- peekArray0 nullPtr c_environ_p mapM peekCString arr foreign import ccall unsafe "&environ" - c_environ_p :: Ptr (Ptr CString) + c_environ_p :: Ptr CString -- |'getEnvironment' retrieves the entire environment as a -- list of @(key,value)@ pairs. |