* src/groupmod.c: Check atexit failures.
This commit is contained in:
		| @@ -2,6 +2,7 @@ | ||||
|  | ||||
| 	* src/groupmod.c: Ignore return value from snprintf. | ||||
| 	* src/groupmod.c: Add static qualifier to the cleanup structures. | ||||
| 	* src/groupmod.c: Check atexit failures. | ||||
|  | ||||
| 2011-08-15  Nicolas François  <nicolas.francois@centraliens.net> | ||||
|  | ||||
|   | ||||
| @@ -736,7 +736,6 @@ int main (int argc, char **argv) | ||||
| #ifdef WITH_AUDIT | ||||
| 	audit_help_open (); | ||||
| #endif | ||||
| 	atexit (do_cleanups); | ||||
|  | ||||
| 	/* | ||||
| 	 * Get my name so that I can use it to report errors. | ||||
| @@ -747,6 +746,13 @@ int main (int argc, char **argv) | ||||
| 	(void) bindtextdomain (PACKAGE, LOCALEDIR); | ||||
| 	(void) textdomain (PACKAGE); | ||||
|  | ||||
| 	if (atexit (do_cleanups) != 0) { | ||||
| 		fprintf (stderr, | ||||
| 		         _("%s: Cannot setup cleanup service.\n"), | ||||
| 		         Prog); | ||||
| 		exit (1); | ||||
| 	} | ||||
|  | ||||
| 	process_flags (argc, argv); | ||||
|  | ||||
| 	OPENLOG ("groupmod"); | ||||
|   | ||||
		Reference in New Issue
	
	Block a user