mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2026-01-01 18:50:12 +01:00
initrd: avoid coverity warning in parse_ip() about "Dereference before null check"
get_word() only moves the "argument" pointer forward. It never sets it
to %NULL. Also, above we already dereference argument, so Coverity thinks
that this NULL check indicates a bug.
Drop it to silence Coverity.
(cherry picked from commit 4596d7793c)
This commit is contained in:
parent
c347e81a1d
commit
2ecc7e8cb5
1 changed files with 1 additions and 1 deletions
|
|
@ -244,7 +244,7 @@ parse_ip (GHashTable *connections, const char *sysfs_dir, char *argument)
|
|||
dns[0] = tmp;
|
||||
dns[1] = get_word (&argument, ':');
|
||||
dns_addr_family[1] = guess_ip_address_family (dns[1]);
|
||||
if (argument && *argument)
|
||||
if (*argument)
|
||||
_LOGW (LOGD_CORE, "Ignoring extra: '%s'.", argument);
|
||||
} else {
|
||||
mtu = tmp;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue