diff options
author | John Hawthorn <john.hawthorn@gmail.com> | 2014-08-30 19:25:44 -0700 |
---|---|---|
committer | John Hawthorn <john.hawthorn@gmail.com> | 2014-08-30 19:48:29 -0700 |
commit | 5c4ad167f745d4351e7ce5419f80ed14393ff52b (patch) | |
tree | 83873b80184a58567d8fac008f10f1a6e14581fa /match.c | |
parent | aa98e4a4f0ef111902e6fd0faf24c8daf953330a (diff) |
D[0][0] need not be initialized to 0
Diffstat (limited to 'match.c')
-rw-r--r-- | match.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -111,7 +111,7 @@ double calculate_score(const char *needle, const char *haystack, size_t *positio for(int i = 0; i < n; i++){ for(int j = 0; j < m; j++){ - score_t score = (j || i) ? SCORE_MIN : 0; + score_t score = SCORE_MIN; int match = tolower(needle[i]) == tolower(haystack[j]); D[i][j] = SCORE_MIN; if(match){ |