Bug #1566800: make sure that EnvironmentError can be called with any
number of arguments, as was the case in Python 2.4.
 (backport from rev. 52061)
diff --git a/Objects/exceptions.c b/Objects/exceptions.c
index bfe28a9..c0b813d 100644
--- a/Objects/exceptions.c
+++ b/Objects/exceptions.c
@@ -510,7 +510,7 @@
     if (BaseException_init((PyBaseExceptionObject *)self, args, kwds) == -1)
         return -1;
 
-    if (PyTuple_GET_SIZE(args) <= 1) {
+    if (PyTuple_GET_SIZE(args) <= 1 || PyTuple_GET_SIZE(args) > 3) {
         return 0;
     }