summaryrefslogtreecommitdiff
path: root/tests/libtest/mk-lib1521.pl
diff options
context:
space:
mode:
authorDaniel Stenberg <daniel@haxx.se>2017-06-09 01:02:12 +0200
committerng0 <ng0@infotropique.org>2017-08-22 15:27:03 +0000
commit485f9aeef04cf4671089118eac4d171af6646fd7 (patch)
treee1477641e2c18ab63e080c0b46246d091424b673 /tests/libtest/mk-lib1521.pl
parentd507304ea18586b165d1bee96dd9784e5c68d9fc (diff)
downloadgnurl-485f9aeef04cf4671089118eac4d171af6646fd7.tar.gz
gnurl-485f9aeef04cf4671089118eac4d171af6646fd7.tar.bz2
gnurl-485f9aeef04cf4671089118eac4d171af6646fd7.zip
lib1521: fix compiler warnings on the use of bad 'long' values
Reported-by: Marcel Raad Bug: https://github.com/curl/curl/commit/cccac4fb2b20d6ed87da7978408c3ecacc464fe4#commitcomment-22453387
Diffstat (limited to 'tests/libtest/mk-lib1521.pl')
-rw-r--r--tests/libtest/mk-lib1521.pl8
1 files changed, 4 insertions, 4 deletions
diff --git a/tests/libtest/mk-lib1521.pl b/tests/libtest/mk-lib1521.pl
index 9cd03b37c..b1eaba8d8 100644
--- a/tests/libtest/mk-lib1521.pl
+++ b/tests/libtest/mk-lib1521.pl
@@ -24,9 +24,9 @@
# Usage:
# cat ../../include/curl/curl.h | perl mk-lib1521.pl > lib1521.c
-# minimum and maximum 32 signed values
-my $minlong = - (1<<31)+1;
-my $maxlong = (1<<31);
+# minimum and maximum long signed values
+my $minlong = "LONG_MIN";
+my $maxlong = "LONG_MAX";
print <<HEADER
/***************************************************************************
@@ -51,8 +51,8 @@ print <<HEADER
*
***************************************************************************/
#include "test.h"
-
#include "memdebug.h"
+#include <limits.h>
/* This source code is generated by mk-lib1521.pl ! */