diff options
author | Serhiy Storchaka <storchaka@gmail.com> | 2022-12-03 19:52:21 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-12-03 19:52:21 (GMT) |
commit | a87c46eab3c306b1c5b8a072b7b30ac2c50651c0 (patch) | |
tree | 92c0ebdb6abd303ea967c0bd999d839a98f84494 /Modules/_ssl.c | |
parent | c68573b339320409b038501fdd7d4f8a56766275 (diff) | |
download | cpython-a87c46eab3c306b1c5b8a072b7b30ac2c50651c0.zip cpython-a87c46eab3c306b1c5b8a072b7b30ac2c50651c0.tar.gz cpython-a87c46eab3c306b1c5b8a072b7b30ac2c50651c0.tar.bz2 |
bpo-15999: Accept arbitrary values for boolean parameters. (#15609)
builtins and extension module functions and methods that expect boolean values for parameters now accept any Python object rather than just a bool or int type. This is more consistent with how native Python code itself behaves.
Diffstat (limited to 'Modules/_ssl.c')
-rw-r--r-- | Modules/_ssl.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/Modules/_ssl.c b/Modules/_ssl.c index 2885774..591eb91 100644 --- a/Modules/_ssl.c +++ b/Modules/_ssl.c @@ -4168,7 +4168,7 @@ _ssl__SSLContext_load_dh_params(PySSLContext *self, PyObject *filepath) /*[clinic input] _ssl._SSLContext._wrap_socket sock: object(subclass_of="get_state_ctx(self)->Sock_Type") - server_side: int + server_side: bool server_hostname as hostname_obj: object = None * owner: object = None @@ -4180,7 +4180,7 @@ static PyObject * _ssl__SSLContext__wrap_socket_impl(PySSLContext *self, PyObject *sock, int server_side, PyObject *hostname_obj, PyObject *owner, PyObject *session) -/*[clinic end generated code: output=f103f238633940b4 input=f5916eadbc6eae81]*/ +/*[clinic end generated code: output=f103f238633940b4 input=700ca8fedff53994]*/ { char *hostname = NULL; PyObject *res; @@ -4205,7 +4205,7 @@ _ssl__SSLContext__wrap_socket_impl(PySSLContext *self, PyObject *sock, _ssl._SSLContext._wrap_bio incoming: object(subclass_of="get_state_ctx(self)->PySSLMemoryBIO_Type", type="PySSLMemoryBIO *") outgoing: object(subclass_of="get_state_ctx(self)->PySSLMemoryBIO_Type", type="PySSLMemoryBIO *") - server_side: int + server_side: bool server_hostname as hostname_obj: object = None * owner: object = None @@ -4218,7 +4218,7 @@ _ssl__SSLContext__wrap_bio_impl(PySSLContext *self, PySSLMemoryBIO *incoming, PySSLMemoryBIO *outgoing, int server_side, PyObject *hostname_obj, PyObject *owner, PyObject *session) -/*[clinic end generated code: output=5c5d6d9b41f99332 input=331edeec9c738382]*/ +/*[clinic end generated code: output=5c5d6d9b41f99332 input=a9205d097fd45a82]*/ { char *hostname = NULL; PyObject *res; |