]> git.ipfire.org Git - thirdparty/util-linux.git/commitdiff
lsblk: fix COL_SCHED
authorKarel Zak <kzak@redhat.com>
Wed, 20 Jun 2018 10:58:19 +0000 (12:58 +0200)
committerKarel Zak <kzak@redhat.com>
Thu, 21 Jun 2018 11:19:28 +0000 (13:19 +0200)
Signed-off-by: Karel Zak <kzak@redhat.com>
misc-utils/lsblk.c

index 156fcb46686f46adc4f8c943e41cc6bf49b50144..a6c78a268f524c0ab513cb9c6e3b0696d45ee79c 100644 (file)
@@ -692,7 +692,7 @@ static char *get_scheduler(struct blkdev_cxt *cxt)
        char buf[128];
        char *p, *res = NULL;
 
-       if (ul_path_read_buffer(cxt->sysfs, buf, sizeof(buf), "queue/scheduler"))
+       if (ul_path_read_buffer(cxt->sysfs, buf, sizeof(buf), "queue/scheduler") == 0)
                return NULL;
        p = strchr(buf, '[');
        if (p) {