]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
sd-device: minor may be NULL
authorYu Watanabe <watanabe.yu+github@gmail.com>
Sun, 10 Apr 2022 13:36:33 +0000 (22:36 +0900)
committerYu Watanabe <watanabe.yu+github@gmail.com>
Mon, 11 Apr 2022 10:56:38 +0000 (19:56 +0900)
src/libsystemd/sd-device/sd-device.c

index 2bddd81c082381dd0eecdd91bb682b54c8974383..343a120b2f6610c6c99baa7370904fb05ce3a819 100644 (file)
@@ -757,7 +757,7 @@ int device_read_uevent_file(sd_device *device) {
         if (major) {
                 r = device_set_devnum(device, major, minor);
                 if (r < 0)
-                        log_device_debug_errno(device, r, "sd-device: Failed to set 'MAJOR=%s' or 'MINOR=%s' from '%s', ignoring: %m", major, minor, path);
+                        log_device_debug_errno(device, r, "sd-device: Failed to set 'MAJOR=%s' or 'MINOR=%s' from '%s', ignoring: %m", major, strna(minor), path);
         }
 
         return 0;