diff options
author | Mike Frysinger <vapier@gentoo.org> | 2005-07-05 02:19:20 +0000 |
---|---|---|
committer | Mike Frysinger <vapier@gentoo.org> | 2005-07-05 02:19:20 +0000 |
commit | 72a4c33568561095fe8d43c8b6f07654c3f593a1 (patch) | |
tree | 85d41530da514dff4dcd08260fdf35b0d2b7a434 | |
parent | b38100974030617ec4fe5b20b38a045df6e92d2d (diff) | |
download | busybox-w32-72a4c33568561095fe8d43c8b6f07654c3f593a1.tar.gz busybox-w32-72a4c33568561095fe8d43c8b6f07654c3f593a1.tar.bz2 busybox-w32-72a4c33568561095fe8d43c8b6f07654c3f593a1.zip |
rename log var to log_console so we dont override internal gcc/glibc log func
-rw-r--r-- | init/init.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/init/init.c b/init/init.c index 850851173..e0e2f19fb 100644 --- a/init/init.c +++ b/init/init.c | |||
@@ -156,7 +156,7 @@ static struct init_action *init_action_list = NULL; | |||
156 | static char console[CONSOLE_BUFF_SIZE] = _PATH_CONSOLE; | 156 | static char console[CONSOLE_BUFF_SIZE] = _PATH_CONSOLE; |
157 | 157 | ||
158 | #ifndef CONFIG_SYSLOGD | 158 | #ifndef CONFIG_SYSLOGD |
159 | static char *log = VC_5; | 159 | static char *log_console = VC_5; |
160 | #endif | 160 | #endif |
161 | static sig_atomic_t got_cont = 0; | 161 | static sig_atomic_t got_cont = 0; |
162 | static const int LOG = 0x1; | 162 | static const int LOG = 0x1; |
@@ -239,9 +239,9 @@ static void message(int device, const char *fmt, ...) | |||
239 | /* Take full control of the log tty, and never close it. | 239 | /* Take full control of the log tty, and never close it. |
240 | * It's mine, all mine! Muhahahaha! */ | 240 | * It's mine, all mine! Muhahahaha! */ |
241 | if (log_fd < 0) { | 241 | if (log_fd < 0) { |
242 | if ((log_fd = device_open(log, O_RDWR | O_NDELAY | O_NOCTTY)) < 0) { | 242 | if ((log_fd = device_open(log_console, O_RDWR | O_NDELAY | O_NOCTTY)) < 0) { |
243 | log_fd = -2; | 243 | log_fd = -2; |
244 | bb_error_msg("Bummer, can't write to log on %s!", log); | 244 | bb_error_msg("Bummer, can't write to log on %s!", log_console); |
245 | device = CONSOLE; | 245 | device = CONSOLE; |
246 | } else { | 246 | } else { |
247 | fcntl(log_fd, F_SETFD, FD_CLOEXEC); | 247 | fcntl(log_fd, F_SETFD, FD_CLOEXEC); |
@@ -381,7 +381,7 @@ static void console_init(void) | |||
381 | if (fd < 0) { | 381 | if (fd < 0) { |
382 | /* Perhaps we should panic here? */ | 382 | /* Perhaps we should panic here? */ |
383 | #ifndef CONFIG_SYSLOGD | 383 | #ifndef CONFIG_SYSLOGD |
384 | log = | 384 | log_console = |
385 | #endif | 385 | #endif |
386 | safe_strncpy(console, "/dev/null", sizeof(console)); | 386 | safe_strncpy(console, "/dev/null", sizeof(console)); |
387 | } else { | 387 | } else { |
@@ -393,7 +393,7 @@ static void console_init(void) | |||
393 | if (s == NULL || strcmp(s, "linux") == 0) | 393 | if (s == NULL || strcmp(s, "linux") == 0) |
394 | putenv("TERM=vt102"); | 394 | putenv("TERM=vt102"); |
395 | #ifndef CONFIG_SYSLOGD | 395 | #ifndef CONFIG_SYSLOGD |
396 | log = console; | 396 | log_console = console; |
397 | #endif | 397 | #endif |
398 | } else { | 398 | } else { |
399 | if (s == NULL) | 399 | if (s == NULL) |