From: Dennis Schafroth Date: Tue, 18 Jan 2011 09:38:14 +0000 (+0100) Subject: Fix: use term factor unless disabled X-Git-Tag: v1.5.2~3 X-Git-Url: http://sru.miketaylor.org.uk/cgi-bin?a=commitdiff_plain;h=01468c84307b0f00ff79112b3dd9723b11544e89;p=pazpar2-moved-to-github.git Fix: use term factor unless disabled --- diff --git a/src/session.c b/src/session.c index 7e7a489..93b25ce 100644 --- a/src/session.c +++ b/src/session.c @@ -1269,10 +1269,10 @@ static int ingest_to_cluster(struct client *cl, const char *use_term_factor_str = session_setting_oneval(sdb, PZ_TERMLIST_TERM_FACTOR); int use_term_factor = 1; + // HACK: default to use term factor. int term_factor = 1; - if (use_term_factor_str) + if (use_term_factor_str && use_term_factor_str[0] != 0) use_term_factor = atoi(use_term_factor_str); - if (use_term_factor) { int maxrecs = client_get_maxrecs(cl); int hits = (int) client_get_hits(cl);