virtio-serial: fix crash on port hotplug when a previously-added port
did not have the 'name' property set.
virtio-serial: fix segfault on NULL port names
Commit d0a0bfe6729ef6044d76ea49fafa07e29fa598bd added checks for port
names, but didn't add a check to ensure port->name is non-NULL. This
results in a SIGSEGV when adding a port when one of the previously-added
ports didn't have the 'name' property set.
Reported-by: vivian zhang <email@example.com>
Reviewed-by: Markus Armbruster <firstname.lastname@example.org>
Signed-off-by: Amit Shah <email@example.com>
1 file changed