Subject: | [PATCH] Fix inline variable declarations |
One of the recent versions added a few inline variable declarations that cause errors for older compilers. Apologies if the patch looks weird, I tried to match the odd tab/space mix going on in this bit of the code.
Subject: | Net-SSLeay-1.78-inline-variables.patch |
From 67263d02ed713003572370931f3d3cc8a773600d Mon Sep 17 00:00:00 2001
From: Andy Grundman <andyg@activestate.com>
Date: Fri, 9 Sep 2016 16:54:04 -0400
Subject: [PATCH] Fix inline variable declarations to make MSVC happy
---
SSLeay.xs | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/SSLeay.xs b/SSLeay.xs
index abd7f42..8404d68 100644
--- a/SSLeay.xs
+++ b/SSLeay.xs
@@ -6043,6 +6043,8 @@ OCSP_response_results(rsp,...)
OCSP_SINGLERESP *sir = NULL;
OCSP_CERTID *certid = NULL;
SV *idsv = NULL;
+ int first, status, revocationReason;
+ ASN1_GENERALIZEDTIME *revocationTime, *thisupdate, *nextupdate;
if(getall) {
sir = OCSP_resp_get0(bsr,i);
@@ -6057,13 +6059,11 @@ OCSP_response_results(rsp,...)
error = "failed to get OCSP certid from string";
goto end;
}
- int first = OCSP_resp_find(bsr, certid, -1); /* Find the first matching */
- if (first >= 0)
- sir = OCSP_resp_get0(bsr,first);
+ first = OCSP_resp_find(bsr, certid, -1); /* Find the first matching */
+ if (first >= 0)
+ sir = OCSP_resp_get0(bsr,first);
}
- int status, revocationReason;
- ASN1_GENERALIZEDTIME *revocationTime, *thisupdate, *nextupdate;
if (sir)
{
#if OPENSSL_VERSION_NUMBER >= 0x10100000L
--
2.8.1