svn commit: trunk/busybox/init
aldot at busybox.net
aldot at busybox.net
Tue May 30 18:17:23 UTC 2006
Author: aldot
Date: 2006-05-30 11:17:21 -0700 (Tue, 30 May 2006)
New Revision: 15239
Log:
- consolidate "Sending SIG%s to all processes"; untested..
text data bss dec hex filename
5379 32 8 5419 152b init/init.o.oorig
5358 32 8 5398 1516 init/init.o
Modified:
trunk/busybox/init/init.c
trunk/busybox/init/init_shared.c
trunk/busybox/init/init_shared.h
Changeset:
Modified: trunk/busybox/init/init.c
===================================================================
--- trunk/busybox/init/init.c 2006-05-30 15:49:10 UTC (rev 15238)
+++ trunk/busybox/init/init.c 2006-05-30 18:17:21 UTC (rev 15239)
@@ -683,12 +683,12 @@
sync();
/* Send signals to every process _except_ pid 1 */
- message(CONSOLE | LOG, "Sending SIGTERM to all processes.");
+ message(CONSOLE | LOG, init_sending_format, "TERM");
kill(-1, SIGTERM);
sleep(1);
sync();
- message(CONSOLE | LOG, "Sending SIGKILL to all processes.");
+ message(CONSOLE | LOG, init_sending_format, "KILL");
kill(-1, SIGKILL);
sleep(1);
Modified: trunk/busybox/init/init_shared.c
===================================================================
--- trunk/busybox/init/init_shared.c 2006-05-30 15:49:10 UTC (rev 15238)
+++ trunk/busybox/init/init_shared.c 2006-05-30 18:17:21 UTC (rev 15239)
@@ -44,16 +44,16 @@
sync();
/* Send signals to every process _except_ pid 1 */
- message = "Sending SIGTERM to all processes.";
- syslog(pri, "%s", message);
+ message = "TERM";
+ syslog(pri, init_sending_format, message);
printf(bb_shutdown_format, message);
kill(-1, SIGTERM);
sleep(1);
sync();
- message = "Sending SIGKILL to all processes.";
- syslog(pri, "%s", message);
+ message = "KILL";
+ syslog(pri, init_sending_format, message);
printf(bb_shutdown_format, message);
kill(-1, SIGKILL);
Modified: trunk/busybox/init/init_shared.h
===================================================================
--- trunk/busybox/init/init_shared.h 2006-05-30 15:49:10 UTC (rev 15238)
+++ trunk/busybox/init/init_shared.h 2006-05-30 18:17:21 UTC (rev 15239)
@@ -1,3 +1,4 @@
extern int kill_init(int sig);
extern int bb_shutdown_system(unsigned long magic);
+const char * const init_sending_format = "Sending SIG%s to all processes.";
More information about the busybox-cvs
mailing list