mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2026-01-06 10:50:14 +01:00
clients: avoid crash in _complete_fcn_connection_master()
Found by coverity, but not a practical issue, because we
wouldn't actually call the function with text NULL.
(cherry picked from commit 8cb86d947c)
This commit is contained in:
parent
18e8f99eb3
commit
ee77657727
1 changed files with 1 additions and 1 deletions
|
|
@ -2448,7 +2448,7 @@ _complete_fcn_connection_master (ARGS_COMPLETE_FCN)
|
|||
expected_type = nm_setting_connection_get_slave_type (s_con);
|
||||
}
|
||||
|
||||
text_len = strlen (text);
|
||||
text_len = text ? strlen (text) : 0;
|
||||
|
||||
result = g_new (char *, (2 * len) + 1);
|
||||
for (i = 0, j = 0; i < len; i++) {
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue