Switch to unified view

a/src/common/rclconfig.cpp b/src/common/rclconfig.cpp
...
...
13
 *   along with this program; if not, write to the
13
 *   along with this program; if not, write to the
14
 *   Free Software Foundation, Inc.,
14
 *   Free Software Foundation, Inc.,
15
 *   59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
15
 *   59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
16
 */
16
 */
17
#ifndef TEST_RCLCONFIG
17
#ifndef TEST_RCLCONFIG
18
#include "autoconfig.h"
19
18
#include <unistd.h>
20
#include <unistd.h>
19
#include <fcntl.h>
21
#include <fcntl.h>
20
#include <stdio.h>
22
#include <stdio.h>
21
#include <errno.h>
23
#include <errno.h>
22
#include <langinfo.h>
24
#include <langinfo.h>
...
...
32
#endif
34
#endif
33
35
34
#include <iostream>
36
#include <iostream>
35
#include <cstdlib>
37
#include <cstdlib>
36
#include <cstring>
38
#include <cstring>
39
using namespace std;
37
40
38
#include "cstr.h"
41
#include "cstr.h"
39
#include "pathut.h"
42
#include "pathut.h"
40
#include "rclconfig.h"
43
#include "rclconfig.h"
41
#include "conftree.h"
44
#include "conftree.h"
...
...
43
#include "smallut.h"
46
#include "smallut.h"
44
#include "textsplit.h"
47
#include "textsplit.h"
45
#include "readfile.h"
48
#include "readfile.h"
46
#include "fstreewalk.h"
49
#include "fstreewalk.h"
47
50
48
#ifndef NO_NAMESPACES
51
#ifndef RCL_INDEX_STRIPCHARS
49
using namespace std;
52
bool o_index_stripchars;
50
#endif /* NO_NAMESPACES */
51
52
#ifndef MIN
53
#define MIN(A,B) (((A)<(B)) ? (A) : (B))
54
#endif
55
#ifndef MAX
56
#define MAX(A,B) (((A)>(B)) ? (A) : (B))
57
#endif
53
#endif
58
54
59
bool ParamStale::needrecompute()
55
bool ParamStale::needrecompute()
60
{
56
{
61
    LOGDEB2(("ParamStale:: needrecompute. parent gen %d mine %d\n", 
57
    LOGDEB2(("ParamStale:: needrecompute. parent gen %d mine %d\n", 
...
...
75
            return true;
71
            return true;
76
        }
72
        }
77
    }
73
    }
78
    return false;
74
    return false;
79
}
75
}
76
80
void ParamStale::init(RclConfig *rconf, ConfNull *cnf, const string& nm)
77
void ParamStale::init(RclConfig *rconf, ConfNull *cnf, const string& nm)
81
{
78
{
82
    parent = rconf;
79
    parent = rconf;
83
    conffile = cnf;
80
    conffile = cnf;
84
    paramname = nm;
81
    paramname = nm;
...
...
236
    bool fnmpathname = true;
233
    bool fnmpathname = true;
237
    if (getConfParam("skippedPathsFnmPathname", &fnmpathname)
234
    if (getConfParam("skippedPathsFnmPathname", &fnmpathname)
238
    && fnmpathname == false) {
235
    && fnmpathname == false) {
239
    FsTreeWalker::setNoFnmPathname();
236
    FsTreeWalker::setNoFnmPathname();
240
    }
237
    }
238
239
#ifndef RCL_INDEX_STRIPCHARS
240
    static int m_index_stripchars_init = 0;
241
    if (!m_index_stripchars_init) {
242
  getConfParam("indexStripChars", &o_index_stripchars);
243
  m_index_stripchars_init = 1;
244
    }
245
#endif
241
246
242
    return true;
247
    return true;
243
}
248
}
244
249
245
ConfNull *RclConfig::cloneMainConfig()
250
ConfNull *RclConfig::cloneMainConfig()