]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
udev: 'val' may be NULL, use strempty()
authorYu Watanabe <watanabe.yu+github@gmail.com>
Wed, 16 Jan 2019 04:02:04 +0000 (13:02 +0900)
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Wed, 16 Jan 2019 12:34:04 +0000 (13:34 +0100)
src/udev/udev-builtin.c

index 3a61be10caa32fe1731a2069b81f33eba5cff9ea..48ce295a46513fcc250e3ca29ec12775d965b6c7 100644 (file)
@@ -139,7 +139,7 @@ int udev_builtin_add_property(sd_device *dev, bool test, const char *key, const
                                               key, val ? "=" : "", strempty(val));
 
         if (test)
-                printf("%s=%s\n", key, val);
+                printf("%s=%s\n", key, strempty(val));
 
         return 0;
 }