diff options
| author | Albrecht Schlosser <albrechts.fltk@online.de> | 2021-12-11 14:49:42 +0100 |
|---|---|---|
| committer | Albrecht Schlosser <albrechts.fltk@online.de> | 2021-12-11 14:49:42 +0100 |
| commit | 20f7db27ba7dc1cf9b2afc4b0e2dc2dda9c8d4de (patch) | |
| tree | 12b91792ee0d749a9d2712f67c6975bfdfb43858 /fluid/shell_command.cxx | |
| parent | 8e864bae21bcebb3d40c140dca44f95bb5b95e94 (diff) | |
Fluid: use fl_strdup() to fix MSVC compiler warning
Diffstat (limited to 'fluid/shell_command.cxx')
| -rw-r--r-- | fluid/shell_command.cxx | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/fluid/shell_command.cxx b/fluid/shell_command.cxx index 14e46ab05..147525989 100644 --- a/fluid/shell_command.cxx +++ b/fluid/shell_command.cxx @@ -21,6 +21,7 @@ #include <FL/Fl_Double_Window.H> #include <FL/fl_message.H> +#include <FL/fl_string.h> #include <errno.h> @@ -88,7 +89,7 @@ void shell_settings_read() free((void*)g_shell_command); g_shell_command = NULL; if (shell_settings.command) - g_shell_command = strdup(shell_settings.command); + g_shell_command = fl_strdup(shell_settings.command); g_shell_save_fl = ((shell_settings.flags&1)==1); g_shell_save_code = ((shell_settings.flags&2)==2); g_shell_save_strings = ((shell_settings.flags&4)==4); @@ -112,7 +113,7 @@ void shell_settings_write() free((void*)shell_settings.command); shell_settings.command = NULL; if (g_shell_command) - shell_settings.command = strdup(g_shell_command); + shell_settings.command = fl_strdup(g_shell_command); shell_settings.flags = 0; if (g_shell_save_fl) shell_settings.flags |= 1; @@ -364,7 +365,7 @@ void update_shell_window() { void apply_shell_window() { if (g_shell_command) free((void*)g_shell_command); - g_shell_command = strdup(shell_command_input->value()); + g_shell_command = fl_strdup(shell_command_input->value()); g_shell_save_fl = shell_savefl_button->value(); g_shell_save_code = shell_writecode_button->value(); g_shell_save_strings = shell_writemsgs_button->value(); |
