Browse Source

(execute_menu_command): fix memory leak.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
Andrew Borodin 3 years ago
parent
commit
f657d92e52
1 changed files with 1 additions and 0 deletions
  1. 1 0
      src/usermenu.c

+ 1 - 0
src/usermenu.c

@@ -480,6 +480,7 @@ execute_menu_command (const WEdit * edit_widget, const char *commands, gboolean
                 if (parameter == NULL || *parameter == '\0')
                 {
                     /* User canceled */
+                    g_free (parameter);
                     fclose (cmd_file);
                     mc_unlink (file_name_vpath);
                     vfs_path_free (file_name_vpath, TRUE);