Removed false warning from Summary.cpp

it warned if maxchars*maxlines were more thatn maxsummary, but it actually didn't do anything about it. I kept the harcoded minimum for maxchars to 10
This commit is contained in:
Ivan Skytte Jørgensen
2016-09-20 14:57:23 +02:00
parent b2a1f77666
commit 912e403174

@ -145,21 +145,8 @@ bool Summary::setSummary ( Xml *xml, Words *words, Sections *sections, Pos *pos,
m_numDisplayLines = numDisplayLines;
m_displayLen = 0;
// assume we got maxnumlines of summary
if ( (maxNumCharsPerLine + 6) * maxNumLines > maxSummaryLen ) {
if ( maxNumCharsPerLine < 10 ) {
maxNumCharsPerLine = 10;
}
static char s_flag = 1;
if ( s_flag ) {
s_flag = 0;
log("query: Warning. "
"Max summary excerpt length decreased to "
"%" PRId32" chars because max summary excerpts and "
"max summary length are too big.",
maxNumCharsPerLine);
}
if ( maxNumCharsPerLine < 10 ) {
maxNumCharsPerLine = 10;
}
// . sanity check