HomeFreeBSD

Verify parent_dev before calling udev_device_get_sysattr_value

Description

Verify parent_dev before calling udev_device_get_sysattr_value

Not all udev devices have parent devices.
Calling udev_device_get_ functions yield an assertion error
if called with a NULL pointer.

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Reviewed-by: Alexander Motin <mav@FreeBSD.org>
Signed-off-by: Sietse <sietse@wizdom.nu>
Co-authored-by: Sietse <sietse@wizdom.nu>
Closes #16705
Closes #16717

Details

Provenance
Uglymotha <uglymotha@wizdom.nu>Authored on Tue, Nov 5, 12:44 AM
GitHub <noreply@github.com>Committed on Tue, Nov 5, 12:44 AM
Parents
rGb16e096198ba: Reduce dirty records memory usage
Branches
Unknown
Tags
Unknown

Event Timeline

GitHub <noreply@github.com> committed rGc8aed9f97329: Verify parent_dev before calling udev_device_get_sysattr_value (authored by Uglymotha <uglymotha@wizdom.nu>).Tue, Nov 5, 12:44 AM