aboutsummaryrefslogtreecommitdiff
path: root/patches/rfc5280.c.patch
diff options
context:
space:
mode:
authorBrent Cook <bcook@openbsd.org>2015-11-02 20:22:26 -0600
committerBrent Cook <bcook@openbsd.org>2015-11-02 20:22:26 -0600
commit1d5dfff695d7bfb32521f4f8c7c296e27b18e908 (patch)
tree0b31b0444b8f39d47d338a9cf3e9f3d93da0f579 /patches/rfc5280.c.patch
parent7180bed3bb78144e19c1dfe3180b0dd2f426bf60 (diff)
downloadportable-1d5dfff695d7bfb32521f4f8c7c296e27b18e908.tar.gz
portable-1d5dfff695d7bfb32521f4f8c7c296e27b18e908.tar.bz2
portable-1d5dfff695d7bfb32521f4f8c7c296e27b18e908.zip
update patches
Diffstat (limited to 'patches/rfc5280.c.patch')
-rw-r--r--patches/rfc5280.c.patch20
1 files changed, 10 insertions, 10 deletions
diff --git a/patches/rfc5280.c.patch b/patches/rfc5280.c.patch
index 4281109..9262183 100644
--- a/patches/rfc5280.c.patch
+++ b/patches/rfc5280.c.patch
@@ -1,5 +1,5 @@
1--- tests/rfc5280time.c.orig Sat Oct 17 22:36:27 2015 1--- tests/rfc5280time.c.orig Mon Nov 2 20:00:31 2015
2+++ tests/rfc5280time.c Sat Oct 17 22:44:25 2015 2+++ tests/rfc5280time.c Mon Nov 2 20:03:12 2015
3@@ -91,6 +91,7 @@ 3@@ -91,6 +91,7 @@
4 .data = "20150923032700Z", 4 .data = "20150923032700Z",
5 .time = 1442978820, 5 .time = 1442978820,
@@ -10,7 +10,7 @@
10 .str = "00000101000000Z", 10 .str = "00000101000000Z",
11@@ -103,6 +104,7 @@ 11@@ -103,6 +104,7 @@
12 .data = "20491231235959Z", 12 .data = "20491231235959Z",
13 .time = 2524607999, 13 .time = 2524607999LL,
14 }, 14 },
15+#endif 15+#endif
16 { 16 {
@@ -18,7 +18,7 @@
18 .str = "19500101000000Z", 18 .str = "19500101000000Z",
19@@ -112,6 +114,7 @@ 19@@ -112,6 +114,7 @@
20 }; 20 };
21 21
22 struct rfc5280_time_test rfc5280_gentime_tests[] = { 22 struct rfc5280_time_test rfc5280_gentime_tests[] = {
23+#if SIZEOF_TIME_T == 8 23+#if SIZEOF_TIME_T == 8
24 { 24 {
@@ -26,7 +26,7 @@
26 .str = "99991231235959Z", 26 .str = "99991231235959Z",
27@@ -129,6 +132,7 @@ 27@@ -129,6 +132,7 @@
28 .data = "20500101000000Z", 28 .data = "20500101000000Z",
29 .time = 2524608000, 29 .time = 2524608000LL,
30 }, 30 },
31+#endif 31+#endif
32 }; 32 };
@@ -40,21 +40,21 @@
40 { 40 {
41 .str = "491231235959Z", 41 .str = "491231235959Z",
42 .data = "491231235959Z", 42 .data = "491231235959Z",
43 .time = 2524607999, 43 .time = 2524607999LL,
44 }, 44 },
45+#endif 45+#endif
46 { 46 {
47 .str = "700101000000Z", 47 .str = "700101000000Z",
48 .data = "700101000000Z", 48 .data = "700101000000Z",
49@@ -273,14 +279,14 @@ 49@@ -273,14 +279,14 @@
50 50
51 if ((i = X509_cmp_time(gt, &att->time)) != -1) { 51 if ((i = X509_cmp_time(gt, &att->time)) != -1) {
52 fprintf(stderr, "FAIL: test %i - X509_cmp_time failed - returned %d compared to %lld\n", 52 fprintf(stderr, "FAIL: test %i - X509_cmp_time failed - returned %d compared to %lld\n",
53- test_no, i, att->time); 53- test_no, i, att->time);
54+ test_no, i, (long long)att->time); 54+ test_no, i, (long long)att->time);
55 goto done; 55 goto done;
56 } 56 }
57 57
58 att->time--; 58 att->time--;
59 if ((i = X509_cmp_time(gt, &att->time)) != 1) { 59 if ((i = X509_cmp_time(gt, &att->time)) != 1) {
60 fprintf(stderr, "FAIL: test %i - X509_cmp_time failed - returned %d compared to %lld\n", 60 fprintf(stderr, "FAIL: test %i - X509_cmp_time failed - returned %d compared to %lld\n",
@@ -64,14 +64,14 @@
64 } 64 }
65 att->time++; 65 att->time++;
66@@ -325,14 +331,14 @@ 66@@ -325,14 +331,14 @@
67 67
68 if ((i = X509_cmp_time(ut, &att->time)) != -1) { 68 if ((i = X509_cmp_time(ut, &att->time)) != -1) {
69 fprintf(stderr, "FAIL: test %i - X509_cmp_time failed - returned %d compared to %lld\n", 69 fprintf(stderr, "FAIL: test %i - X509_cmp_time failed - returned %d compared to %lld\n",
70- test_no, i, att->time); 70- test_no, i, att->time);
71+ test_no, i, (long long)att->time); 71+ test_no, i, (long long)att->time);
72 goto done; 72 goto done;
73 } 73 }
74 74
75 att->time--; 75 att->time--;
76 if ((i = X509_cmp_time(ut, &att->time)) != 1) { 76 if ((i = X509_cmp_time(ut, &att->time)) != 1) {
77 fprintf(stderr, "FAIL: test %i - X509_cmp_time failed - returned %d compared to %lld\n", 77 fprintf(stderr, "FAIL: test %i - X509_cmp_time failed - returned %d compared to %lld\n",