mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2025-12-27 09:20:08 +01:00
libnm-core: fix a crash in priority_strv_to_maplist()
strv can be NULL.
Reproducer:
$ nmcli con mod my-vlan vlan.ingress 1:5
(cherry picked from commit 71c8c2e587)
This commit is contained in:
parent
7ac3b75f42
commit
7cfd6fc641
1 changed files with 1 additions and 1 deletions
|
|
@ -565,7 +565,7 @@ priority_strv_to_maplist (NMVlanPriorityMap map, char **strv)
|
|||
GSList *list = NULL;
|
||||
int i;
|
||||
|
||||
for (i = 0; strv[i]; i++) {
|
||||
for (i = 0; strv && strv[i]; i++) {
|
||||
PriorityMap *item;
|
||||
|
||||
item = priority_map_new_from_str (map, strv[i]);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue