Author: Karl Ramm <[email protected]>
Branch: py3k
Changeset: r62396:979b3dd2b1a5
Date: 2013-03-18 01:51 -0400
http://bitbucket.org/pypy/pypy/changeset/979b3dd2b1a5/

Log:    python3 ssl constructor actually raises ValueError on illegal
        protocol

diff --git a/pypy/module/_ssl/interp_ssl.py b/pypy/module/_ssl/interp_ssl.py
--- a/pypy/module/_ssl/interp_ssl.py
+++ b/pypy/module/_ssl/interp_ssl.py
@@ -116,7 +116,8 @@
         elif protocol == PY_SSL_VERSION_SSL23:
             method = libssl_SSLv23_method()
         else:
-            raise ssl_error(space, "invalid SSL protocol version")
+            raise OperationError(
+                space.w_ValueError, space.wrap("invalid protocol version"))
         self.__init__(method)
         if not self.ctx:
             raise ssl_error(space, "failed to allocate SSL context")
_______________________________________________
pypy-commit mailing list
[email protected]
http://mail.python.org/mailman/listinfo/pypy-commit

Reply via email to