Bug 1402362 - modified NET_MAX_ADDRESS to have UINTPTR_MAX value. r?valentin draft
authorAndi-Bogdan Postelnicu <bpostelnicu@mozilla.com>
Wed, 27 Sep 2017 15:09:29 +0300
changeset 671093 083c62ac669fb7c3146c4370b1526645d58112cb
parent 671089 35fbf14b96a633c3f66ea13c1a163a3f3a4219b9
child 733405 8dc28e596a533789a66d4722e374707db3319287
push id81816
push userbmo:bpostelnicu@mozilla.com
push dateWed, 27 Sep 2017 12:13:04 +0000
reviewersvalentin
bugs1402362
milestone58.0a1
Bug 1402362 - modified NET_MAX_ADDRESS to have UINTPTR_MAX value. r?valentin MozReview-Commit-ID: 4tPNMWypVFo
netwerk/base/nsURLHelper.h
--- a/netwerk/base/nsURLHelper.h
+++ b/netwerk/base/nsURLHelper.h
@@ -216,17 +216,17 @@ void net_ParseContentType(const nsACStri
                           nsACString       &aContentCharset,
                           bool             *aHadCharset,
                           int32_t          *aCharsetStart,
                           int32_t          *aCharsetEnd);
 
 /* inline versions */
 
 /* remember the 64-bit platforms ;-) */
-#define NET_MAX_ADDRESS (((char*)0)-1)
+#define NET_MAX_ADDRESS ((char*)UINTPTR_MAX)
 
 inline char *net_FindCharInSet(const char *str, const char *set)
 {
     return net_FindCharInSet(str, NET_MAX_ADDRESS, set);
 }
 inline char *net_FindCharNotInSet(const char *str, const char *set)
 {
     return net_FindCharNotInSet(str, NET_MAX_ADDRESS, set);