diff hgext/mq.py @ 7421:4c4324476be6

Catch both IOError and OSError, fix regression introduced by 8046f0a070a6
author Benoit Boissinot <benoit.boissinot@ens-lyon.org>
date Wed, 26 Nov 2008 18:23:35 +0100
parents 040484030491
children 9898427add1c
line wrap: on
line diff
--- a/hgext/mq.py	Tue Nov 25 18:45:08 2008 -0800
+++ b/hgext/mq.py	Wed Nov 26 18:23:35 2008 +0100
@@ -1583,7 +1583,7 @@
                         text = sys.stdin.read()
                     else:
                         text = url.open(self.ui, filename).read()
-                except IOError:
+                except (OSError, IOError):
                     raise util.Abort(_("unable to read %s") % filename)
                 if not patchname:
                     patchname = normname(os.path.basename(filename))