indexing log: fix idx/daemlogfilename not working as expected
This commit is contained in:
@@ -248,7 +248,7 @@ void recoll_exitready()
|
||||
|
||||
#endif
|
||||
|
||||
RclConfig *recollinit(RclInitFlags flags,
|
||||
RclConfig *recollinit(int flags,
|
||||
void (*cleanup)(void), void (*sigcleanup)(int),
|
||||
string &reason, const string *argcnf)
|
||||
{
|
||||
@@ -281,10 +281,14 @@ RclConfig *recollinit(RclInitFlags flags,
|
||||
config->getConfParam(string("daemlogfilename"), logfilename);
|
||||
config->getConfParam(string("daemloglevel"), loglevel);
|
||||
}
|
||||
if ((flags & RCLINIT_IDX) && logfilename.empty())
|
||||
config->getConfParam(string("idxlogfilename"), logfilename);
|
||||
if ((flags & RCLINIT_IDX) && loglevel.empty())
|
||||
config->getConfParam(string("idxloglevel"), loglevel);
|
||||
if (flags & RCLINIT_IDX) {
|
||||
if (logfilename.empty()) {
|
||||
config->getConfParam(string("idxlogfilename"), logfilename);
|
||||
}
|
||||
if (loglevel.empty()) {
|
||||
config->getConfParam(string("idxloglevel"), loglevel);
|
||||
}
|
||||
}
|
||||
|
||||
if (logfilename.empty())
|
||||
config->getConfParam(string("logfilename"), logfilename);
|
||||
|
||||
@@ -40,7 +40,7 @@ class RclConfig;
|
||||
* @return the parsed configuration.
|
||||
*/
|
||||
enum RclInitFlags {RCLINIT_NONE = 0, RCLINIT_DAEMON = 1, RCLINIT_IDX = 2};
|
||||
extern RclConfig *recollinit(RclInitFlags flags,
|
||||
extern RclConfig *recollinit(int flags,
|
||||
void (*cleanup)(void), void (*sigcleanup)(int),
|
||||
std::string& reason, const string *argcnf = 0);
|
||||
inline RclConfig *recollinit(void (*cleanup)(void), void (*sigcleanup)(int),
|
||||
|
||||
Reference in New Issue
Block a user