hgext/largefiles/remotestore.py
changeset 52640 24ee91ba9aa8
parent 51859 f4733654f144
child 52643 5cc8deb96b48
--- a/hgext/largefiles/remotestore.py	Mon Jan 06 14:15:40 2025 -0500
+++ b/hgext/largefiles/remotestore.py	Sun Jan 05 21:03:17 2025 -0500
@@ -62,7 +62,7 @@
         try:
             with lfutil.httpsendfile(self.ui, filename) as fd:
                 return self._put(hash, fd)
-        except IOError as e:
+        except OSError as e:
             raise error.Abort(
                 _(b'remotestore: could not open file %s: %s')
                 % (filename, stringutil.forcebytestr(e))
@@ -84,7 +84,7 @@
             raise error.Abort(
                 b'%s: %s' % (urlutil.hidepassword(self.url), e.reason)
             )
-        except IOError as e:
+        except OSError as e:
             raise basestore.StoreError(
                 filename, hash, self.url, stringutil.forcebytestr(e)
             )