]> git.ipfire.org Git - thirdparty/util-linux.git/commitdiff
lib/loopdev: fix compiler warning [-Wcast-qual]
authorKarel Zak <kzak@redhat.com>
Mon, 23 Jul 2018 09:17:28 +0000 (11:17 +0200)
committerKarel Zak <kzak@redhat.com>
Mon, 23 Jul 2018 09:17:28 +0000 (11:17 +0200)
Signed-off-by: Karel Zak <kzak@redhat.com>
lib/loopdev.c

index cab05af94e0ccfaee104d8dbfc55bd591d8d3e97..de0d50ba2db22a76b854052d5e40ab275f814c6c 100644 (file)
@@ -402,8 +402,8 @@ static int loopiter_set_device(struct loopdev_cxt *lc, const char *device)
 
 static int cmpnum(const void *p1, const void *p2)
 {
-       return (((* (int *) p1) > (* (int *) p2)) -
-                       ((* (int *) p1) < (* (int *) p2)));
+       return (((* (const int *) p1) > (* (const int *) p2)) -
+                       ((* (const int *) p1) < (* (const int *) p2)));
 }
 
 /*