]> err.no Git - systemd/commitdiff
udevtest: export UDEV_LOG if we changed it
authorJean Tourrilhes <jt@hpl.hp.com>
Fri, 16 Mar 2007 00:09:47 +0000 (01:09 +0100)
committerKay Sievers <kay.sievers@vrfy.org>
Fri, 16 Mar 2007 00:09:47 +0000 (01:09 +0100)
udevtest.c

index 2854f7558ff3cd8a9c75b5dd2ccce38e10682376..73bf7dd1f8dde459575c11cc55a347cf7141ff49 100644 (file)
@@ -59,8 +59,13 @@ int main(int argc, char *argv[], char *envp[])
 
        info("version %s", UDEV_VERSION);
        udev_config_init();
-       if (udev_log_priority < LOG_INFO)
+       if (udev_log_priority < LOG_INFO) {
+               char priority[32];
+
                udev_log_priority = LOG_INFO;
+               sprintf(priority, "%i", udev_log_priority);
+               setenv("UDEV_LOG", priority, 1);
+       }
 
        for (i = 1 ; i < argc; i++) {
                char *arg = argv[i];