Bug 1530548 - Move the definition of MAXPATHLEN after includes in updatedefines.h. r=mhowell
authorRobert Strong <robert.bugzilla@gmail.com>
Tue, 26 Feb 2019 17:35:31 +0000
changeset 519078 1165806614a45faf998da7ffe8f670e94a5f9030
parent 519077 5d81bc61dfb82e34be9517420f90aa93910d42ab
child 519079 2a9b9f7b3b695a07705960bd2ddc3824f2e21357
push id10862
push userffxbld-merge
push dateMon, 11 Mar 2019 13:01:11 +0000
treeherdermozilla-beta@a2e7f5c935da [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersmhowell
bugs1530548
milestone67.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1530548 - Move the definition of MAXPATHLEN after includes in updatedefines.h. r=mhowell Differential Revision: https://phabricator.services.mozilla.com/D21135
toolkit/mozapps/update/common/updatedefines.h
--- a/toolkit/mozapps/update/common/updatedefines.h
+++ b/toolkit/mozapps/update/common/updatedefines.h
@@ -2,30 +2,16 @@
  * License, v. 2.0. If a copy of the MPL was not distributed with this
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 #ifndef UPDATEDEFINES_H
 #define UPDATEDEFINES_H
 
 #include "readstrings.h"
 
-#ifndef MAXPATHLEN
-#  ifdef PATH_MAX
-#    define MAXPATHLEN PATH_MAX
-#  elif defined(MAX_PATH)
-#    define MAXPATHLEN MAX_PATH
-#  elif defined(_MAX_PATH)
-#    define MAXPATHLEN _MAX_PATH
-#  elif defined(CCHMAXPATH)
-#    define MAXPATHLEN CCHMAXPATH
-#  else
-#    define MAXPATHLEN 1024
-#  endif
-#endif
-
 #if defined(XP_WIN)
 #  include <windows.h>
 #  include <shlwapi.h>
 #  include <direct.h>
 #  include <io.h>
 #  include <stdio.h>
 #  include <stdarg.h>
 
@@ -140,9 +126,23 @@ static inline int mywcsprintf(WCHAR* des
 #  define NS_tdirent dirent
 #  define NS_topendir opendir
 #  define NS_tclosedir closedir
 #  define NS_treaddir readdir
 #endif
 
 #define BACKUP_EXT NS_T(".moz-backup")
 
+#ifndef MAXPATHLEN
+#  ifdef PATH_MAX
+#    define MAXPATHLEN PATH_MAX
+#  elif defined(MAX_PATH)
+#    define MAXPATHLEN MAX_PATH
+#  elif defined(_MAX_PATH)
+#    define MAXPATHLEN _MAX_PATH
+#  elif defined(CCHMAXPATH)
+#    define MAXPATHLEN CCHMAXPATH
+#  else
+#    define MAXPATHLEN 1024
+#  endif
 #endif
+
+#endif