Merge pull request #133 from sureshsundriyal/wip

Code changes to get rid of warnings & errors.
pull/135/head
Tim Stack 10 years ago
commit 0850d75173

@ -227,7 +227,7 @@ const char *log_format::log_scanf(const char *line,
pcre_format *fmt, pcre_format *fmt,
const char *time_fmt[], const char *time_fmt[],
struct exttm *tm_out, struct exttm *tm_out,
struct timeval &tv_out, struct timeval *tv_out,
...) ...)
{ {
int curr_fmt = -1; int curr_fmt = -1;
@ -257,7 +257,7 @@ const char *log_format::log_scanf(const char *line,
} }
retval = this->lf_date_time.scan( retval = this->lf_date_time.scan(
pi.get_substr_start(ts), ts->length(), NULL, tm_out, tv_out); pi.get_substr_start(ts), ts->length(), NULL, tm_out, *tv_out);
if (retval) { if (retval) {
this->lf_fmt_lock = curr_fmt; this->lf_fmt_lock = curr_fmt;

@ -597,7 +597,7 @@ protected:
pcre_format *fmt, pcre_format *fmt,
const char *time_fmt[], const char *time_fmt[],
struct exttm *tm_out, struct exttm *tm_out,
struct timeval &tv_out, struct timeval *tv_out,
...); ...);
}; };

@ -140,7 +140,7 @@ class generic_log_format : public log_format {
get_pcre_log_formats(), get_pcre_log_formats(),
NULL, NULL,
&log_time, &log_time,
log_tv, &log_tv,
&ts, &ts,
&level)) != NULL) { &level)) != NULL) {

@ -1,6 +1,8 @@
#include "config.h" #include "config.h"
#include <time.h> #include <time.h>
#include <sys/time.h>
#include <stddef.h>
time_t time(time_t *loc) time_t time(time_t *loc)
{ {

@ -90,7 +90,7 @@ int main(int argc, char *argv[])
static const char *CANNED_INPUT[] = { static const char *CANNED_INPUT[] = {
"abc", "abc",
"\r", "\r",
tgetstr("ce", NULL), tgetstr((char *)"ce", NULL),
"de", "de",
"\n", "\n",
"1\n", "1\n",

Loading…
Cancel
Save