mirror of
https://github.com/python/cpython
synced 2024-09-16 00:17:02 +00:00
bpo-44389: Fix typo in ssl deprecation warning message (GH-26754)
`ssl.SSL_NO_TLS` should be `ssl.OP_NO_TLS`.
This commit is contained in:
parent
7247f6f433
commit
c544393b89
|
@ -605,7 +605,7 @@ def test_openssl111_deprecations(self):
|
|||
with self.assertWarns(DeprecationWarning) as cm:
|
||||
ctx.options |= option
|
||||
self.assertEqual(
|
||||
'ssl.OP_NO_SSL*/ssl.SSL_NO_TLS* options are deprecated',
|
||||
'ssl.OP_NO_SSL*/ssl.OP_NO_TLS* options are deprecated',
|
||||
str(cm.warning)
|
||||
)
|
||||
|
||||
|
|
|
@ -3597,7 +3597,7 @@ set_options(PySSLContext *self, PyObject *arg, void *c)
|
|||
set = ~opts & new_opts;
|
||||
|
||||
if ((set & opt_no) != 0) {
|
||||
if (_ssl_deprecated("ssl.OP_NO_SSL*/ssl.SSL_NO_TLS* options are "
|
||||
if (_ssl_deprecated("ssl.OP_NO_SSL*/ssl.OP_NO_TLS* options are "
|
||||
"deprecated", 2) < 0) {
|
||||
return -1;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue