diff options
author | Alexey Yakovenko <waker@users.sourceforge.net> | 2014-06-23 18:02:28 +0200 |
---|---|---|
committer | Alexey Yakovenko <waker@users.sourceforge.net> | 2014-06-23 18:02:43 +0200 |
commit | 140b20afd4a688eddbba9855a5f27192a61ad203 (patch) | |
tree | 4991ee2141407378c87ae3046e0545944f086d64 | |
parent | d43b7c86b8fe7e5ef47a78becbca46b121d33d40 (diff) |
fixed --gui cmdline option
-rw-r--r-- | main.c | 4 |
1 files changed, 4 insertions, 0 deletions
@@ -862,6 +862,10 @@ main (int argc, char *argv[]) { return 0; } else if (!strcmp (argv[i], "--gui")) { + if (i == argc-1) { + break; + } + i++; strncpy (use_gui_plugin, argv[i], sizeof(use_gui_plugin) - 1); use_gui_plugin[sizeof(use_gui_plugin) - 1] = 0; } |