aboutsummaryrefslogtreecommitdiffhomepage
path: root/System/Posix/User.hsc
Commit message (Collapse)AuthorAge
* Replace `__hsunix_getpw{nam,uid_r}` wrappers with CApiFFIGravatar Herbert Valerio Riedel2016-01-31
|
* Drop redundant __GLASGOW_HASKELL__ conditionals for GHC>=7.4Gravatar Herbert Valerio Riedel2016-01-31
|
* Replace `__hsunix_getpwent` wrapper with CApiFFIGravatar Herbert Valerio Riedel2016-01-30
|
* `M-x untabify` && `M-x delete-trailing-whitespace`Gravatar Herbert Valerio Riedel2014-12-06
|
* fix getGroupEntryForID/Name on SolarisGravatar Karel Gardas2014-09-10
| | | | | | | | | This patch fixes getGroupEntryForID and getGroupEntryForName on Solaris The issue on Solaris is that it defines both required getgrgid_r and getgrnam_r functions as CPP macros which depending on configuration are mapped to real function implementations with different names. The issue is solved by using C API calling convention instead of platform C ABI calling convention.
* Declare language extensions via `{-# LANGUAGE -#}`Gravatar Herbert Valerio Riedel2013-10-12
| | | | | | | | | Only language extensions not active when `-XHaskell2010` is enabled are declared, this way we can drop many redundant `{-# LANGUAGE ForeignFunctionInterface #-}` occurences. This commit also removes/replaces some `{-# OPTIONS_GHC -XRecordWildCards #-}` pragmas. Signed-off-by: Herbert Valerio Riedel <hvr@gnu.org>
* Unconditionalize imports in System.Posix.UserGravatar Reid Barton2013-10-09
| | | | | | Their use site is now unconditional. Issue #8223. Signed-off-by: Austin Seipp <austin@well-typed.com>
* Extract the result of get*_r before we deallocate the auxiliary bufferGravatar Marios Titas2013-08-10
| | | | | | Also comes with tests. This closes #8108. Signed-off-by: Austin Seipp <aseipp@pobox.com>
* Follow changes in baseGravatar Ian Lynagh2013-02-16
|
* cope with missing pw_gecos (for Android)Gravatar Simon Marlow2013-01-30
| | | | Submitted by: Nathan Hüsken <nathan.huesken@posteo.de>
* Bump base lower version to 4.5 (the version GHC 7.4.1 came with)Gravatar Ian Lynagh2012-11-30
| | | | and remove code to support older versions
* Fix conditional pragma to work with 6.12Gravatar David Terei2011-08-09
|
* Use Safe Haskell when GHC >= 7.2Gravatar David Terei2011-08-03
|
* Improved Unicode support in the light of PEP383Gravatar Max Bolingbroke2011-05-14
|
* Remove unnecessary fromIntegral callsGravatar simonpj@microsoft.com2010-11-16
|
* avoid Foreign.unsafePerformIOGravatar Ross Paterson2010-09-09
|
* Add bindings for setting effective user-id and group-idGravatar Eric Mertens2010-05-17
| | | | | | Having the ability to set the effective user-id and group-id enables the application to switch between the real user-id and set-user-id multiple times.
* make getAllGroupEntries work when called again; fixes #3816Gravatar Simon Marlow2010-03-29
|
* Add comments about why user001 might fail on Linux.Gravatar Simon Marlow2009-09-17
| | | | See http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=466647
* NetBSD does not have support for symbol versioning, so updated systenGravatar Simon Marlow2009-07-23
| | | | | | | | | | | | | | | | | | functions need to be given a new name, and the header files contain some __asm hackery in order to let the program call the correct function. This mean that you need to use the header files in order to call the correct system functions, which prevents things like "foreign import ccall" from working. Ghc solves this with wrapper functions for some of the renamed functions, but it has not been updated for newer versions of NetBSD that has recently versioned some more functions. The attached patches introduces wrapper functions for all currently NetBSD-versioned functions used in libraries/unix. Solves ~20 testsuite failures. Contributed by: Krister Walfridsson <krister.walfridsson@gmail.com>
* Fix some "warn-unused-do-bind" warnings where we want to ignore the valueGravatar Ian Lynagh2009-07-10
|
* Make get{Group,User}EntryBy{ID,Name} more portable.Gravatar Matthias Kilian2009-03-29
| | | | | | | | Retry with a larger buffer whenever getgrgid_r(3), getgrnam_r(3), getpwuid_r(3) or getpwnam_r(3) return ERANGE. Suggested in the examples sections of IEEE Std 1003.1-2008. While here, change the default for grBufSize back to 1024.
* Fix warnings in the unix packageGravatar Ian Lynagh2008-08-21
|
* Avoid using deprecated flagsGravatar Ian Lynagh2008-06-16
|
* Throw a proper exception if getUserEntryForName fails to find an entryGravatar Ian Lynagh2008-01-15
| | | | Fixes trac #2033.
* Throw a proper exception if getGroupEntryForName fails to find an entryGravatar Ian Lynagh2007-11-10
| | | | | | We used to get *** Exception: getGroupEntryForName: failed (Success) Fixes trac #1655
* Fix calling getAllUserEntries twice (trac #1279).Gravatar Ian Lynagh2007-05-04
| | | | | It used to return [] on all but the first call. Patch from an unidentified guest.
* Handle sysconf(3) return value -1 when checking _SC_GETGR_R_SIZE_MAX and ↵Gravatar bjorn@bringert.net2007-04-16
| | | | | | | | _SC_GETPW_R_SIZE_MAX. sysconf(3) returns -1 on failure, but this was not handled when checking _SC_GETGR_R_SIZE_MAX and _SC_GETPW_R_SIZE_MAX in System.Posix.User. This made getUserEntryForID, getUserEntryForName, getGroupEntryForID and getGroupEntryForName fail on OS X 10.4.9 on i386. Just checking that unistd.h defines _SC_GETGR_R_SIZE_MAX and _SC_GETPW_R_SIZE_MAX as was done before does not guarantee that sysconf(3) will succeed. sysconf(3) failure is now handled by using the same default values as were already used when sysconf(3) is not available, or the parameter names are not defined.
* fix haddock syntaxGravatar Simon Marlow2006-09-08
|
* Derive Show, Read, and Eq for UserEntry and GroupEntryGravatar John Goerzen2006-08-31
|
* Fix compilation issues with new getgrent/getpwent codeGravatar John Goerzen2006-08-30
|
* Added support for getpwent/getgrentGravatar John Goerzen2006-08-30
|
* Added some Haddock docs for UserEntry and GroupEntryGravatar John Goerzen2006-08-29
|
* Add missing field gr_passwd to GroupEntryGravatar John Goerzen2006-08-29
|
* Whitespace changes for better alignment in unpackUserEntryGravatar John Goerzen2006-08-29
|
* Added pw_passwd and pw_gecos fields to UserEntry structureGravatar John Goerzen2006-08-29
| | | | | | System.Posix.User was missing pw_gecos and pw_passwd in UserEntry. I have added them, so now the full struct passwd is represented.
* [project @ 2005-11-10 12:58:32 by simonmar]Gravatar simonmar2005-11-10
| | | | Some docs for System.Posix, from Bj?rn Bringert
* [project @ 2004-11-12 13:22:56 by stolz]Gravatar stolz2004-11-12
| | | | More getpw*_r result checks
* [project @ 2004-11-05 14:59:33 by stolz]Gravatar stolz2004-11-05
| | | | | | | | | | | | | | | | Fix getpwnam_r-handling: getpwnam_r returns (always?) 0, you have to check result* (pppw[0])! Truss-log from querying first "root", then "" on SunOS 5.9: <- libc:__posix_getpwnam_r() = 0 "root" -> libc:__posix_getpwnam_r(0xff1bf8a8, 0xff1bf460, 0xff1bf490, 0x400) <- libc:__posix_getpwnam_r() = 0 Yes, that's 0 in both cases. (I wasn't even able to elicit an ERANGE btw.) Reported by: Peter Simons
* [project @ 2004-09-30 03:13:23 by dons]Gravatar dons2004-09-30
| | | | | | | | | | | | Implement System.Posix.User.getUserEntryFor{ID,Name} on platforms without reentrant versions of getpw{uid,nam}. This includes all the BSDs. While I'm here, close getGroupEntryFor* "Result too large" bug on OpenBSD, mentioned last year: http://www.haskell.org/pipermail/glasgow-haskell-bugs/2003-September/003601.html grBufSize was too small, apparently. Thanks to Ian Lynagh for hint to do the locking.
* [project @ 2004-02-19 16:29:28 by stolz]Gravatar stolz2004-02-19
| | | | | | Remove redundant _POSIX_PTHREAD_SEMANTICS. It's defined on the command line and also set too late/in the wrong place (after including system prototypes), anyway.
* [project @ 2003-12-05 10:20:25 by ross]Gravatar ross2003-12-05
| | | | | | | solaris_TARGET_OS -> solaris2_TARGET_OS (and tweak the #define while I'm here) Works for Hugs, still untested for GHC, but presumably needed for STABLE.
* [project @ 2003-10-24 14:38:27 by sof]Gravatar sof2003-10-24
| | | | | | code tidyup merge to stable
* [project @ 2003-09-22 10:57:45 by simonmar]Gravatar simonmar2003-09-22
| | | | | | | Untested fix for Solaris to get the right versions of getgrnam_r and friends. I'd appreciate it if someone with a Solaris build could test this.
* [project @ 2003-04-11 10:11:23 by ross]Gravatar ross2003-04-11
| | | | rename GHC.Posix as System.Posix.Internals
* [project @ 2002-12-26 21:01:46 by panne]Gravatar panne2002-12-26
| | | | | | | | Once again: Make Haddock happy. Running Haddock in addition to ghc (i.e. use 'make all html' instead of plain 'make') before a commit would be nice, especially as buglets like this break a 3 hour RPM build just before it can finish... :-(
* [project @ 2002-12-26 17:52:35 by wolfgang]Gravatar wolfgang2002-12-26
| | | | Mac OS X doesn't have the sysconfig constants _SC_GETPW_R_SIZE_MAX and _SC_GETGR_R_SIZE_MAX, so add a configure check
* [project @ 2002-12-19 13:52:55 by simonmar]Gravatar simonmar2002-12-19
Fill in some more bits in the new Unix library: specifically the contents of PosixTTY and PosixDB (now System.Posix.Terminal and System.Posix.User respectively). We're now about 95% complete w.r.t. the old posix library. I've identified the reminaing bits to do in System/Posix.hs.