mirror of
https://git.kernel.org/pub/scm/network/wireless/iwd.git
synced 2024-12-22 13:02:44 +01:00
client: Make sure network_args.type is initialised
Otherwise match_by_device_and_args might segfault.
This commit is contained in:
parent
61bdb7e19f
commit
18e672fa2f
@ -770,8 +770,7 @@ static enum cmd_status cmd_connect(const char *device_name,
|
||||
return CMD_STATUS_INVALID_ARGS;
|
||||
|
||||
network_args.name = argv[0];
|
||||
if (argc >= 2)
|
||||
network_args.type = argv[1];
|
||||
network_args.type = argc >= 2 ? argv[1] : NULL;
|
||||
|
||||
match = network_match_by_device_and_args(device_proxy, &network_args);
|
||||
if (!match) {
|
||||
|
Loading…
Reference in New Issue
Block a user