X-Git-Url: https://git.archive.openwrt.org/?p=project%2Fprocd.git;a=blobdiff_plain;f=syslog.c;h=416740b8fbc80d7b1c2500ee49b098d0800b540b;hp=a558e50a51b28a0cc3d943db6b036f8ba82bfd09;hb=5c6859ddf9f0ca57e297d2d178504c5ad1c063e7;hpb=f708f887cf30e94288670b2bfe6d7dc561fa4eea diff --git a/syslog.c b/syslog.c index a558e50..416740b 100644 --- a/syslog.c +++ b/syslog.c @@ -46,8 +46,8 @@ static char *log_dev = LOG_DEFAULT_SOCKET; static int log_size = LOG_DEFAULT_SIZE; static struct log_head *log, *log_end, *oldest, *newest; static int current_id = 0; -regex_t pat_prio; -regex_t pat_tstamp; +static regex_t pat_prio; +static regex_t pat_tstamp; static struct log_head *log_next(struct log_head *h, int size) { @@ -165,12 +165,12 @@ static void klog_cb(struct ustream *s, int bytes) struct ustream_fd slog = { .stream.string_data = true, - .stream.notify_read = slog_cb, + .stream.notify_read = slog_cb, }; struct ustream_fd klog = { .stream.string_data = true, - .stream.notify_read = klog_cb, + .stream.notify_read = klog_cb, }; static int klog_open(void) @@ -262,11 +262,6 @@ int log_buffer_init(int size) return 0; } -int log_buffer_size(void) -{ - return log_size; -} - void log_init(void) { regcomp(&pat_prio, "^<([0-9]*)>(.*)", REG_EXTENDED);