Browse code

Really long candidates should return SCORE_MIN

John Hawthorn authored on 17/08/2014 04:07:50
Showing 1 changed files

  • match.c index 427cd6f..4ce6ddb 100644
... ...
@@ -52,7 +52,7 @@ double calculate_score(const char *needle, const char *haystack, size_t *positio
52 52
 		 * If it is a valid match it will still be returned, it will
53 53
 		 * just be ranked below any reasonably sized candidates
54 54
 		 */
55
-		return 0;
55
+		return SCORE_MIN;
56 56
 	}
57 57
 
58 58
 	score_t match_bonus[m];