static struct log_head*
log_next(struct log_head *h, int size)
{
- struct log_head *n = (struct log_head *) &h->data[PAD(sizeof(struct log_head) + size)];
+ struct log_head *n = (struct log_head *) &h->data[PAD(size)];
return (n >= log_end) ? (log) : (n);
}
/* bounce out if we don't have init'ed yet (regmatch etc will blow) */
if (!log) {
- fprintf(stderr, buf);
+ fprintf(stderr, "%s", buf);
return;
}
close(slog.fd.fd);
close(klog.fd.fd);
free(log);
+ regfree(&pat_prio);
+ regfree(&pat_tstamp);
}