summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNick Mathewson <nickm@torproject.org>2011-01-12 14:29:38 -0500
committerNick Mathewson <nickm@torproject.org>2011-01-12 14:29:38 -0500
commit9fcc14224b689dff1be8336feeeb563199694c27 (patch)
treef59ac86e652d339f563067770896c1f4a05d8e6d
parentd43cba6c690d9c227b13cd7426285b82b9523611 (diff)
downloadtor-9fcc14224b689dff1be8336feeeb563199694c27.tar.gz
tor-9fcc14224b689dff1be8336feeeb563199694c27.zip
Make our replacement INT32_MAX always signed
The C standard says that INT32_MAX is supposed to be a signed integer. On platforms that have it, we get the correct platform-defined value. Our own replacement, however, was unsigned. That's going to cause a bug somewhere eventually.
-rw-r--r--src/common/torint.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/common/torint.h b/src/common/torint.h
index 4970dcd674..2a9fba6fcf 100644
--- a/src/common/torint.h
+++ b/src/common/torint.h
@@ -115,7 +115,7 @@ typedef unsigned int uint32_t;
#define UINT32_MAX 0xffffffffu
#endif
#ifndef INT32_MAX
-#define INT32_MAX 0x7fffffffu
+#define INT32_MAX 0x7fffffff
#endif
#endif