libnm: try to avoid coverity warning in assertion()

Coverity thinks that this could be NULL sometimes. Try to check for that
to shut up the warning.
This commit is contained in:
Thomas Haller
2019-08-02 08:52:26 +02:00
parent b5793b74ca
commit f61e274df9

View File

@@ -277,7 +277,7 @@ foreach_item_helper (NMSettingVpn *self,
}
for (i = 0; i < len; i++) {
nm_assert (keys[i]);
nm_assert (keys && keys[i]);
keys[i] = g_strdup (keys[i]);
}
nm_assert (!keys[i]);