]> granicus.if.org Git - python/commitdiff
Merged revisions 72399 via svnmerge from
authorJeroen Ruigrok van der Werven <asmodai@in-nomine.org>
Wed, 6 May 2009 13:18:35 +0000 (13:18 +0000)
committerJeroen Ruigrok van der Werven <asmodai@in-nomine.org>
Wed, 6 May 2009 13:18:35 +0000 (13:18 +0000)
svn+ssh://pythondev@svn.python.org/python/trunk

........
  r72399 | jeroen.ruigrok | 2009-05-06 15:16:36 +0200 (wo, 06 mei 2009) | 4 lines

  Be more explicit about the error we are catching.

  Requested by: Antoine Pitrou
........

Lib/locale.py

index 75a6435430fd8d12caff8865a3ba6d4f7c85e8e1..4441e6d4d022b8690712e0c06ab0f01956449a13 100644 (file)
@@ -566,7 +566,7 @@ else:
                 oldloc = setlocale(LC_CTYPE)
                 try:
                     setlocale(LC_CTYPE, "")
-                except:
+                except Error:
                     pass
                 result = nl_langinfo(CODESET)
                 setlocale(LC_CTYPE, oldloc)