aboutsummaryrefslogtreecommitdiff
path: root/sysdeps/unix/sysv/linux/sys/sysmacros.h
diff options
context:
space:
mode:
Diffstat (limited to 'sysdeps/unix/sysv/linux/sys/sysmacros.h')
-rw-r--r--sysdeps/unix/sysv/linux/sys/sysmacros.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/sysdeps/unix/sysv/linux/sys/sysmacros.h b/sysdeps/unix/sysv/linux/sys/sysmacros.h
index 85b1b85d2e..5c1e1f7441 100644
--- a/sysdeps/unix/sysv/linux/sys/sysmacros.h
+++ b/sysdeps/unix/sysv/linux/sys/sysmacros.h
@@ -22,8 +22,8 @@
#define _SYS_SYSMACROS_H 1
/* For compatibility we provide alternative names. */
-#define major(dev) (((dev) >> 8) & 0xff)
-#define minor(dev) ((dev) & 0xff)
+#define major(dev) ((int)(((dev) >> 8) & 0xff))
+#define minor(dev) ((int)((dev) & 0xff))
#define makedev(major, minor) (((major) << 8) | (minor))
#endif /* _SYS_SYSMACROS_H */