mercurial/sshrepo.py
changeset 3764 6652209d104d
parent 3599 e00920b4f1cb
child 3765 768ba23c948e
--- a/mercurial/sshrepo.py	Sat Dec 02 16:08:00 2006 -0200
+++ b/mercurial/sshrepo.py	Sat Dec 02 21:57:20 2006 +0100
@@ -134,14 +134,10 @@
     def lookup(self, key):
         d = self.call("lookup", key=key)
         success, data = d[:-1].split(" ", 1)
-        try:
-            if int(success):
-                return bin(data)
-            else:
-                raise data
-        except:
-            raise
-            raise hg.RepoError("unexpected response '%s'" % (d[:400] + "..."))
+        if int(success):
+            return bin(data)
+        else:
+            self.repoerror(data)
 
     def heads(self):
         d = self.call("heads")