mirror of
https://github.com/gnustep/libs-base.git
synced 2025-04-23 00:41:02 +00:00
when using MinGW do not try to chdir to /tmp
because it does not always exist. git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@18690 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
59f45702c8
commit
ec9898b2ef
1 changed files with 2 additions and 1 deletions
|
@ -4618,13 +4618,14 @@ printf(
|
|||
/*
|
||||
* As another level of paranoia - restrict this process to /tmp
|
||||
*/
|
||||
#ifndef __MINGW__
|
||||
if (chdir("/tmp") < 0)
|
||||
{
|
||||
sprintf(ebuf, "Unable to change directory to /tmp");
|
||||
gdomap_log(LOG_CRIT);
|
||||
exit(EXIT_FAILURE);
|
||||
}
|
||||
#ifndef __MINGW__
|
||||
|
||||
if (geteuid() == 0)
|
||||
{
|
||||
if (chroot("/tmp") < 0)
|
||||
|
|
Loading…
Reference in a new issue