diff options
Diffstat (limited to 'util-linux/rtcwake.c')
-rw-r--r-- | util-linux/rtcwake.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/util-linux/rtcwake.c b/util-linux/rtcwake.c index 53d9384db..8aee0cfcb 100644 --- a/util-linux/rtcwake.c +++ b/util-linux/rtcwake.c @@ -66,7 +66,7 @@ static NOINLINE bool may_wakeup(const char *rtcname) return false; /* wakeup events could be disabled or not supported */ - return strncmp(buf, "enabled\n", 8) == 0; + return is_prefixed_with(buf, "enabled\n") != NULL; } static NOINLINE void setup_alarm(int fd, time_t *wakeup, time_t rtc_time) |