mirror of
https://github.com/python/cpython.git
synced 2025-12-04 00:30:19 +00:00
Fix a few more variables to try to get this to compile with Visual Studio.
This commit is contained in:
parent
ce7fa56aac
commit
dc988119b5
1 changed files with 3 additions and 2 deletions
|
|
@ -440,6 +440,7 @@ _create_dict_for_X509_NAME (X509_NAME *xname)
|
||||||
PyObject *name_obj;
|
PyObject *name_obj;
|
||||||
ASN1_STRING *value;
|
ASN1_STRING *value;
|
||||||
PyObject *value_obj;
|
PyObject *value_obj;
|
||||||
|
unsigned char *valuebuf = NULL;
|
||||||
|
|
||||||
X509_NAME_ENTRY *entry = X509_NAME_get_entry(xname,
|
X509_NAME_ENTRY *entry = X509_NAME_get_entry(xname,
|
||||||
index_counter);
|
index_counter);
|
||||||
|
|
@ -453,7 +454,6 @@ _create_dict_for_X509_NAME (X509_NAME *xname)
|
||||||
goto fail0;
|
goto fail0;
|
||||||
|
|
||||||
value = X509_NAME_ENTRY_get_data(entry);
|
value = X509_NAME_ENTRY_get_data(entry);
|
||||||
unsigned char *valuebuf = NULL;
|
|
||||||
buflen = ASN1_STRING_to_UTF8(&valuebuf, value);
|
buflen = ASN1_STRING_to_UTF8(&valuebuf, value);
|
||||||
if (buflen < 0) {
|
if (buflen < 0) {
|
||||||
Py_DECREF(name_obj);
|
Py_DECREF(name_obj);
|
||||||
|
|
@ -493,6 +493,7 @@ PySSL_peercert(PySSLObject *self)
|
||||||
int len;
|
int len;
|
||||||
ASN1_TIME *notBefore, *notAfter;
|
ASN1_TIME *notBefore, *notAfter;
|
||||||
PyObject *pnotBefore, *pnotAfter;
|
PyObject *pnotBefore, *pnotAfter;
|
||||||
|
int verification;
|
||||||
|
|
||||||
if (!self->peer_cert)
|
if (!self->peer_cert)
|
||||||
Py_RETURN_NONE;
|
Py_RETURN_NONE;
|
||||||
|
|
@ -501,7 +502,7 @@ PySSL_peercert(PySSLObject *self)
|
||||||
if (retval == NULL)
|
if (retval == NULL)
|
||||||
return NULL;
|
return NULL;
|
||||||
|
|
||||||
int verification = SSL_CTX_get_verify_mode(self->ctx);
|
verification = SSL_CTX_get_verify_mode(self->ctx);
|
||||||
if ((verification & SSL_VERIFY_PEER) == 0)
|
if ((verification & SSL_VERIFY_PEER) == 0)
|
||||||
return retval;
|
return retval;
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue