summaryrefslogtreecommitdiffstats
path: root/src/udev/udevadm-settle.c
diff options
context:
space:
mode:
authorYu Watanabe <watanabe.yu+github@gmail.com>2022-08-27 18:04:56 +0200
committerYu Watanabe <watanabe.yu+github@gmail.com>2022-08-29 06:40:54 +0200
commitd0dfd9fd325001e27aed1828b8ae0e03193b56bd (patch)
tree0ac8a0b574d98d87fbed09b208bd1c558d06d70d /src/udev/udevadm-settle.c
parentudevadm-settle: check if udevd is running (diff)
downloadsystemd-d0dfd9fd325001e27aed1828b8ae0e03193b56bd.tar.xz
systemd-d0dfd9fd325001e27aed1828b8ae0e03193b56bd.zip
udevadm-settle: rename arg_timeout -> arg_timeout_usec
Diffstat (limited to 'src/udev/udevadm-settle.c')
-rw-r--r--src/udev/udevadm-settle.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/udev/udevadm-settle.c b/src/udev/udevadm-settle.c
index 1bb047f442..b61875a6e7 100644
--- a/src/udev/udevadm-settle.c
+++ b/src/udev/udevadm-settle.c
@@ -29,7 +29,7 @@
#include "util.h"
#include "virt.h"
-static usec_t arg_timeout = 120 * USEC_PER_SEC;
+static usec_t arg_timeout_usec = 120 * USEC_PER_SEC;
static const char *arg_exists = NULL;
static int help(void) {
@@ -61,7 +61,7 @@ static int parse_argv(int argc, char *argv[]) {
while ((c = getopt_long(argc, argv, "t:E:Vhs:e:q", options, NULL)) >= 0) {
switch (c) {
case 't':
- r = parse_sec(optarg, &arg_timeout);
+ r = parse_sec(optarg, &arg_timeout_usec);
if (r < 0)
return log_error_errno(r, "Failed to parse timeout value '%s': %m", optarg);
break;
@@ -174,7 +174,7 @@ int settle_main(int argc, char *argv[], void *userdata) {
(void) emit_deprecation_warning();
- deadline = now(CLOCK_MONOTONIC) + arg_timeout;
+ deadline = now(CLOCK_MONOTONIC) + arg_timeout_usec;
if (getuid() == 0) {
_cleanup_(udev_ctrl_unrefp) UdevCtrl *uctrl = NULL;
@@ -191,7 +191,7 @@ int settle_main(int argc, char *argv[], void *userdata) {
return 0;
}
- r = udev_ctrl_wait(uctrl, MAX(5 * USEC_PER_SEC, arg_timeout));
+ r = udev_ctrl_wait(uctrl, MAX(5 * USEC_PER_SEC, arg_timeout_usec));
if (r < 0)
return log_error_errno(r, "Failed to wait for daemon to reply: %m");
} else {