mirror of
https://git.openldap.org/openldap/openldap.git
synced 2025-12-26 17:49:59 -05:00
slight change to chdir/chroot commit to clean up perror args
This commit is contained in:
parent
0189c35b6a
commit
ef51582b6e
1 changed files with 11 additions and 4 deletions
|
|
@ -301,10 +301,17 @@ int main( int argc, char **argv )
|
|||
}
|
||||
|
||||
#if defined(HAVE_CHROOT)
|
||||
if ( sandbox && chdir( sandbox ) && chroot( sandbox ) ) {
|
||||
perror("chroot");
|
||||
rc = 1;
|
||||
goto stop;
|
||||
if ( sandbox ) {
|
||||
if ( chdir( sandbox ) ) {
|
||||
perror("chdir");
|
||||
rc = 1;
|
||||
goto stop;
|
||||
}
|
||||
if ( chroot( sandbox ) ) {
|
||||
perror("chroot");
|
||||
rc = 1;
|
||||
goto stop;
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue