Check RECOLL_LOGDATE environment variable to add date stamps to the debug log. Closes issue #246
This commit is contained in:
parent
d78b7069cc
commit
929e2a1715
@ -77,6 +77,9 @@ RclConfig *recollinit(RclInitFlags flags,
|
|||||||
|
|
||||||
DebugLog::getdbl()->setloglevel(DEBDEB1);
|
DebugLog::getdbl()->setloglevel(DEBDEB1);
|
||||||
DebugLog::setfilename("stderr");
|
DebugLog::setfilename("stderr");
|
||||||
|
if (getenv("RECOLL_LOGDATE"))
|
||||||
|
DebugLog::getdbl()->logdate(1);
|
||||||
|
|
||||||
RclConfig *config = new RclConfig(argcnf);
|
RclConfig *config = new RclConfig(argcnf);
|
||||||
if (!config || !config->ok()) {
|
if (!config || !config->ok()) {
|
||||||
reason = "Configuration could not be built:\n";
|
reason = "Configuration could not be built:\n";
|
||||||
|
|||||||
@ -398,10 +398,14 @@ DebugLog *getdbl()
|
|||||||
#else /* TEST_DEBUGLOG */
|
#else /* TEST_DEBUGLOG */
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
|
#include <stdlib.h>
|
||||||
|
#include <unistd.h>
|
||||||
|
#include <string.h>
|
||||||
|
|
||||||
#include "debuglog.h"
|
#include "debuglog.h"
|
||||||
|
|
||||||
#if DEBUGLOG_USE_THREADS
|
#if DEBUGLOG_USE_THREADS
|
||||||
#define TEST_THREADS
|
//#define TEST_THREADS
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef TEST_THREADS
|
#ifdef TEST_THREADS
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user