From: Kurt Zeilenga Date: Mon, 9 Oct 2000 23:38:30 +0000 (+0000) Subject: slight change to chdir/chroot commit to clean up perror args X-Git-Tag: LDBM_PRE_GIANT_RWLOCK~1790 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=ef51582b6e28963c1717e060eaa67560b625e19b;p=openldap slight change to chdir/chroot commit to clean up perror args --- diff --git a/servers/slapd/main.c b/servers/slapd/main.c index ccf2f93c04..f729ec6377 100644 --- a/servers/slapd/main.c +++ b/servers/slapd/main.c @@ -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