38 static pthread_mutex_t
mutex = PTHREAD_MUTEX_INITIALIZER;
89 time_t now = time(NULL);
113 static time_t lasterror = (time_t) 0;
117 if (nberr <
MAX_ERR || lasterror + 60 < now) {
118 if ((logname == NULL) || (strlen(logname) == 0)) {
132 if (!
log_printf(&logt,
"%10ld %12s IP=(%s) TAG=(%s) %3d %3d %s\n",
133 (
long) now,
id, ip, tag,
nb, score, expr)) {
140 id,
STRNULL(tag,
"NOTAG"),
nb, score, expr);
#define MUTEX_UNLOCK(mutex)
bool log_open(LOG_T *, char *)
#define MUTEX_LOCK(mutex)
#define ZE_LogMsgError(level,...)
#define CF_REGEX_LOG_FILE
bool log_printf(LOG_T *, char *,...)
#define CF_DUMP_FOUND_REGEX
#define ZE_MessageInfo(level,...)
bool log_found_regex(char *id, char *ip, char *tag, int nb, int score, char *expr)
char * cf_get_str(int id)
#define ADJUST_LOG_NAME(path, fname, dir, defval)