From cefbaf779b0fc402a6cccd1edc5df950d3125fb7 Mon Sep 17 00:00:00 2001 From: Paul Beckingham Date: Sat, 31 May 2014 17:23:00 -0400 Subject: [PATCH] Parser - ::initialize only overrides Parser::minimumMatchLength when rc.abbreviation.minimum is non-zero. --- src/Parser.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/Parser.cpp b/src/Parser.cpp index 9910ee037..029c27038 100644 --- a/src/Parser.cpp +++ b/src/Parser.cpp @@ -69,7 +69,9 @@ Parser::~Parser () void Parser::initialize (int argc, const char** argv) { // Set up constants. - minimumMatchLength = strtol (context.config.get ("abbreviation.minimum").c_str (), NULL, 10); + int override = context.config.getInteger ("abbreviation.minimum"); + if (override) + minimumMatchLength = override; // Create top-level nodes. for (int i = 0; i < argc; ++i)