Fix POSIX compliance
* "WAIT_MYPGRP" isn't POSIX'ish. Relying on this caused compilation issues in certain environments (e.g. under Cygwin). As a workaround, define "WAIT_MYPGRP" explicitly if it's undefined. * "P_tmpdir" is an XSI extension. Don't try use it if it isn't available. Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
This commit is contained in:
@@ -523,8 +523,10 @@ get_tempdir (void)
|
||||
{
|
||||
if (getenv ("TMPDIR"))
|
||||
return getenv ("TMPDIR");
|
||||
#ifdef P_tmpdir
|
||||
else if (P_tmpdir)
|
||||
return P_tmpdir;
|
||||
#endif
|
||||
else
|
||||
return "/tmp";
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user