mirror of
https://github.com/Tha14/toxic.git
synced 2024-11-23 00:53:03 +01:00
fix segfault on unknown long option
This commit is contained in:
parent
b1c7e21ca9
commit
155e194174
@ -201,7 +201,7 @@ int settings_load(struct user_settings *s, const char *patharg)
|
|||||||
{
|
{
|
||||||
config_t cfg[1];
|
config_t cfg[1];
|
||||||
config_setting_t *setting;
|
config_setting_t *setting;
|
||||||
const char *str;
|
const char *str = NULL;
|
||||||
|
|
||||||
/* Load default settings */
|
/* Load default settings */
|
||||||
ui_defaults(s);
|
ui_defaults(s);
|
||||||
|
@ -619,6 +619,7 @@ static void parse_args(int argc, char *argv[])
|
|||||||
{"dnslist", required_argument, 0, 'r'},
|
{"dnslist", required_argument, 0, 'r'},
|
||||||
{"force-tcp", no_argument, 0, 't'},
|
{"force-tcp", no_argument, 0, 't'},
|
||||||
{"proxy", required_argument, 0, 'p'},
|
{"proxy", required_argument, 0, 'p'},
|
||||||
|
{NULL, no_argument, NULL, 0},
|
||||||
};
|
};
|
||||||
|
|
||||||
const char *opts_str = "4bdhotxc:f:n:r:p:";
|
const char *opts_str = "4bdhotxc:f:n:r:p:";
|
||||||
|
Loading…
Reference in New Issue
Block a user