Coverity #1247398, #1199692, #1321278, #1321279, #1321280, #1321281, #1097625 fixed...
[scilab.git] / scilab / modules / scinotes / src / cpp / callscinotes.cpp
index 163833b..8d78af9 100644 (file)
@@ -129,7 +129,11 @@ int callSciNotesWWithOption(wchar_t **_wcfilenames, wchar_t** option, int _nbopt
                 }
             }
         }
-        FREE(opt);
+        for(int i = 0; i < _nboptions; i++)
+        {
+            FREE(opt[i]);
+        }
+        delete[] opt;
     }
     else
     {