diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-05-04 01:11:51 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-05-04 01:11:51 +0000 |
commit | a6f3675fc4e21b3f899286b9a02005368d913f74 (patch) | |
tree | c9bfa92b223783ff03b8e941c3bb0d36c68d3b5e /src/filemanager/command.c | |
parent | Releasing progress-linux version 3:4.8.30-1~progress7.99u1. (diff) | |
download | mc-a6f3675fc4e21b3f899286b9a02005368d913f74.tar.xz mc-a6f3675fc4e21b3f899286b9a02005368d913f74.zip |
Merging upstream version 3:4.8.31.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'src/filemanager/command.c')
-rw-r--r-- | src/filemanager/command.c | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/src/filemanager/command.c b/src/filemanager/command.c index 47d2d75..360f104 100644 --- a/src/filemanager/command.c +++ b/src/filemanager/command.c @@ -4,7 +4,7 @@ with all the magic of the command input line, we depend on some help from the program's callback. - Copyright (C) 1995-2023 + Copyright (C) 1995-2024 Free Software Foundation, Inc. Written by: @@ -139,8 +139,11 @@ enter (WInput * lc_cmdline) char *s; s = expand_format (NULL, cmd[++i], TRUE); - g_string_append (command, s); - g_free (s); + if (s != NULL) + { + g_string_append (command, s); + g_free (s); + } } } @@ -248,8 +251,11 @@ command_insert (WInput * in, const char *text, gboolean insert_extra_space) char *quoted_text; quoted_text = name_quote (text, TRUE); - input_insert (in, quoted_text, insert_extra_space); - g_free (quoted_text); + if (quoted_text != NULL) + { + input_insert (in, quoted_text, insert_extra_space); + g_free (quoted_text); + } } /* --------------------------------------------------------------------------------------------- */ |