diff options
author | Gerald (Jerry) Carter <jerry@samba.org> | 2007-10-10 15:34:30 -0500 |
---|---|---|
committer | Gerald (Jerry) Carter <jerry@samba.org> | 2007-10-10 15:34:30 -0500 |
commit | e5a951325a6cac8567af3a66de6d2df577508ae4 (patch) | |
tree | 34da9fe59f3c2d7f8edb072144443a9704197831 /source3/tests/getgroups.c | |
parent | 57482469b32645250e92a7ffd003aeeb4a42235e (diff) | |
download | samba-e5a951325a6cac8567af3a66de6d2df577508ae4.tar.gz samba-e5a951325a6cac8567af3a66de6d2df577508ae4.tar.bz2 samba-e5a951325a6cac8567af3a66de6d2df577508ae4.zip |
[GLUE] Rsync SAMBA_3_2_0 SVN r25598 in order to create the v3-2-test branch.
(This used to be commit 5c6c8e1fe93f340005110a7833946191659d88ab)
Diffstat (limited to 'source3/tests/getgroups.c')
-rw-r--r-- | source3/tests/getgroups.c | 14 |
1 files changed, 5 insertions, 9 deletions
diff --git a/source3/tests/getgroups.c b/source3/tests/getgroups.c index c73cd21650..343fd5a184 100644 --- a/source3/tests/getgroups.c +++ b/source3/tests/getgroups.c @@ -11,10 +11,6 @@ #include <unistd.h> #endif -#if defined(HAVE_STDLIB_H) -#include <stdlib.h> -#endif - #include <sys/types.h> #include <stdio.h> #include <unistd.h> @@ -30,7 +26,7 @@ main() if (sizeof(gid_t) == sizeof(int)) { fprintf(stderr,"gid_t and int are the same size\n"); - return 1; + exit(1); } if (ngroups <= 0) @@ -48,7 +44,7 @@ main() if (ngroups == 0) { printf("WARNING: can't determine getgroups return type\n"); - return 1; + exit(1); } cgroups = (char *)igroups; @@ -56,15 +52,15 @@ main() if (ngroups == 1 && cgroups[2] == 0x42 && cgroups[3] == 0x42) { fprintf(stderr,"getgroups returns gid_t\n"); - return 1; + exit(1); } for (i=0;i<ngroups;i++) { if (igroups[i] == 0x42424242) { fprintf(stderr,"getgroups returns gid_t\n"); - return 1; + exit(1); } } - return 0; + exit(0); } |