Don't try to avoid calling free(3) with NULL argument.
MFC after: 1 month Sponsored by: The FreeBSD Foundation
This commit is contained in:
parent
9f72f0ee52
commit
c2ef20fdb7
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=290821
@ -515,8 +515,7 @@ conf_new_from_kernel(void)
|
||||
STAILQ_FOREACH(port, &devlist.port_list, links) {
|
||||
if (strcmp(port->port_frontend, "ha") == 0)
|
||||
continue;
|
||||
if (name)
|
||||
free(name);
|
||||
free(name);
|
||||
if (port->pp == 0 && port->vp == 0)
|
||||
name = checked_strdup(port->port_name);
|
||||
else if (port->vp == 0)
|
||||
@ -583,8 +582,7 @@ conf_new_from_kernel(void)
|
||||
}
|
||||
cp->p_ctl_port = port->port_id;
|
||||
}
|
||||
if (name)
|
||||
free(name);
|
||||
free(name);
|
||||
|
||||
STAILQ_FOREACH(lun, &devlist.lun_list, links) {
|
||||
struct cctl_lun_nv *nv;
|
||||
|
Loading…
Reference in New Issue
Block a user