hwclock: fix ul_path_scanf() use

Signed-off-by: Karel Zak <kzak@redhat.com>
This commit is contained in:
Karel Zak 2021-06-18 16:50:58 +02:00
parent ddadf4748d
commit 365e006a36
1 changed files with 1 additions and 1 deletions

View File

@ -441,7 +441,7 @@ get_hardware_delay(const struct hwclock_control *ctl)
pc = ul_new_path("/sys/class/rtc/%s", rtcname);
if (!pc)
goto unknown;
rc = ul_path_scanf(pc, "name", "%128[^\n ]", &name);
rc = ul_path_scanf(pc, "name", "%128[^\n ]", name);
ul_unref_path(pc);
if (rc != 1 || !*name)