Fix completion after 18201 & 9bfcd2 17/18217/2
Paul Bignier [Mon, 6 Jun 2016 08:41:54 +0000 (10:41 +0200)]
 * gcc 4.8.5 requires end of array
 * Typing "-->/mo" and pressing TAB crashed Scilab

Change-Id: I9b4fe3f2f7b1c24e56416e0d5319a7e15d4840bf

scilab/modules/completion/src/c/completion.c

index d968bf1..d1cbf1d 100644 (file)
@@ -279,6 +279,7 @@ char **completionOnVariablesWithoutMacros(const char *somechars, int *sizeArrayR
             {
                 ListWords[i] = os_strdup(dictionaryVariables[i]);
             }
+            ListWords[sizedictionaryVariables] = 0x0;
             *sizeArrayReturned = sizedictionaryVariables;
         }