Bug 1329798 - Include sys/sysmacros.h for major(), minor() on Linux. r=glandium, a=jcristau
authorMichał Górny <mgorny@gentoo.org>
Wed, 15 Feb 2017 00:49:00 +0100
changeset 376324 d4e8a7b1832dc6cfe52b8a9dcf0133b2733418cb
parent 376323 32f96350bb4964b1f111edb9b3746fb3c0dcbda1
child 376325 025f8110974059ac7884d8b4316c9168afcc8d96
push id6996
push userjlorenzo@mozilla.com
push dateMon, 06 Mar 2017 20:48:21 +0000
treeherdermozilla-beta@d89512dab048 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersglandium, jcristau
bugs1329798
milestone53.0a2
Bug 1329798 - Include sys/sysmacros.h for major(), minor() on Linux. r=glandium, a=jcristau Include sys/sysmacros.h explicitly as that will be required by future glibc versions to expose major() and minor() macros. Bug: https://bugzilla.mozilla.org/show_bug.cgi?id=1329798
config/system-headers
xpcom/io/nsLocalFileUnix.cpp
--- a/config/system-headers
+++ b/config/system-headers
@@ -1050,16 +1050,17 @@ sys/sockio.h
 sys/sparc/frame.h
 sys/stack.h
 sys/statfs.h
 sys/stat.h
 sys/statvfs.h
 sys/syscall.h
 sys/sysctl.h
 sys/sysinfo.h
+sys/sysmacros.h
 sys/sysmp.h
 sys/syssgi.h
 sys/system_properties.h
 sys/systeminfo.h
 sys/timeb.h
 sys/time.h
 sys/times.h
 sys/ttycom.h
--- a/xpcom/io/nsLocalFileUnix.cpp
+++ b/xpcom/io/nsLocalFileUnix.cpp
@@ -21,16 +21,17 @@
 #include <dirent.h>
 #include <ctype.h>
 #include <locale.h>
 
 #if defined(HAVE_SYS_QUOTA_H) && defined(HAVE_LINUX_QUOTA_H)
 #define USE_LINUX_QUOTACTL
 #include <sys/mount.h>
 #include <sys/quota.h>
+#include <sys/sysmacros.h>
 #ifndef BLOCK_SIZE
 #define BLOCK_SIZE 1024 /* kernel block size */
 #endif
 #endif
 
 #include "xpcom-private.h"
 #include "nsDirectoryServiceDefs.h"
 #include "nsCRT.h"