From: Wolfgang Bumiller Date: Thu, 10 Jan 2013 20:09:44 +0000 (+0100) Subject: correction fix: don't try to create edits for an empty string X-Git-Tag: before-library~316 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=fa90d2d06e0c2c7c32071f6b0350df2c6260fdc2;p=xonotic%2Fgmqcc.git correction fix: don't try to create edits for an empty string --- diff --git a/correct.c b/correct.c index 2062a15..aa94ee6 100644 --- a/correct.c +++ b/correct.c @@ -478,6 +478,8 @@ static char **correct_known(correction_t *corr, correct_trie_t* table, char **ar char **end = NULL; for (; itr < rows; itr++) { + if (!array[itr][0]) + continue; if (vec_size(corr->edits) > itr+1) end = corr->edits[itr+1]; else {