aboutsummaryrefslogtreecommitdiff
path: root/runit/svlogd.c
diff options
context:
space:
mode:
Diffstat (limited to 'runit/svlogd.c')
-rw-r--r--runit/svlogd.c18
1 files changed, 9 insertions, 9 deletions
diff --git a/runit/svlogd.c b/runit/svlogd.c
index 41a7c860e..59b1e5721 100644
--- a/runit/svlogd.c
+++ b/runit/svlogd.c
@@ -75,7 +75,7 @@ static struct logdir {
75 char match; 75 char match;
76 char matcherr; 76 char matcherr;
77} *dir; 77} *dir;
78static unsigned dirn = 0; 78static unsigned dirn;
79 79
80#define FATAL "fatal: " 80#define FATAL "fatal: "
81#define WARNING "warning: " 81#define WARNING "warning: "
@@ -83,18 +83,18 @@ static unsigned dirn = 0;
83#define INFO "info: " 83#define INFO "info: "
84 84
85#define usage() bb_show_usage() 85#define usage() bb_show_usage()
86static void fatalx(char *m0) 86static void fatalx(const char *m0)
87{ 87{
88 bb_error_msg_and_die(FATAL"%s", m0); 88 bb_error_msg_and_die(FATAL"%s", m0);
89} 89}
90static void warn(char *m0) { 90static void warn(const char *m0) {
91 bb_perror_msg(WARNING"%s", m0); 91 bb_perror_msg(WARNING"%s", m0);
92} 92}
93static void warn2(char *m0, char *m1) 93static void warn2(const char *m0, const char *m1)
94{ 94{
95 bb_perror_msg(WARNING"%s: %s", m0, m1); 95 bb_perror_msg(WARNING"%s: %s", m0, m1);
96} 96}
97static void warnx(char *m0, char *m1) 97static void warnx(const char *m0, const char *m1)
98{ 98{
99 bb_error_msg(WARNING"%s: %s", m0, m1); 99 bb_error_msg(WARNING"%s: %s", m0, m1);
100} 100}
@@ -103,12 +103,12 @@ static void pause_nomem(void)
103 bb_error_msg(PAUSE"out of memory"); 103 bb_error_msg(PAUSE"out of memory");
104 sleep(3); 104 sleep(3);
105} 105}
106static void pause1cannot(char *m0) 106static void pause1cannot(const char *m0)
107{ 107{
108 bb_perror_msg(PAUSE"cannot %s", m0); 108 bb_perror_msg(PAUSE"cannot %s", m0);
109 sleep(3); 109 sleep(3);
110} 110}
111static void pause2cannot(char *m0, char *m1) 111static void pause2cannot(const char *m0, const char *m1)
112{ 112{
113 bb_perror_msg(PAUSE"cannot %s %s", m0, m1); 113 bb_perror_msg(PAUSE"cannot %s %s", m0, m1);
114 sleep(3); 114 sleep(3);
@@ -168,8 +168,8 @@ static unsigned processorstart(struct logdir *ld)
168 bb_perror_msg_and_die(FATAL"cannot %s processor %s", "move filedescriptor for", ld->name); 168 bb_perror_msg_and_die(FATAL"cannot %s processor %s", "move filedescriptor for", ld->name);
169 169
170// getenv("SHELL")? 170// getenv("SHELL")?
171 prog[0] = "sh"; 171 prog[0] = (char*)"sh";
172 prog[1] = "-c"; 172 prog[1] = (char*)"-c";
173 prog[2] = ld->processor; 173 prog[2] = ld->processor;
174 prog[3] = '\0'; 174 prog[3] = '\0';
175 execve("/bin/sh", prog, environ); 175 execve("/bin/sh", prog, environ);