]> git.ipfire.org Git - thirdparty/mdadm.git/blobdiff - util.c
in_initrd: fix gcc compiler error
[thirdparty/mdadm.git] / util.c
diff --git a/util.c b/util.c
index 8096e2976f937c9c83346b7203e3fc84525923d0..491a1075c72f88db1f727dbc0ec2140602f930b4 100644 (file)
--- a/util.c
+++ b/util.c
@@ -1949,6 +1949,6 @@ int in_initrd(void)
        /* This is based on similar function in systemd. */
        struct statfs s;
        return  statfs("/", &s) >= 0 &&
-               (s.f_type == TMPFS_MAGIC ||
-                s.f_type == RAMFS_MAGIC);
+               ((unsigned long)s.f_type == TMPFS_MAGIC ||
+                (unsigned long)s.f_type == RAMFS_MAGIC);
 }