Mercurial > public > mercurial-scm > hg-stable
comparison mercurial/sshrepo.py @ 3764:6652209d104d
Don't show traceback on 'hg clone -r unknown ssh://hg.example.com/'.
author | Thomas Arendsen Hein <thomas@intevation.de> |
---|---|
date | Sat, 02 Dec 2006 21:57:20 +0100 |
parents | e00920b4f1cb |
children | 768ba23c948e |
comparison
equal
deleted
inserted
replaced
3762:b9d3e12da485 | 3764:6652209d104d |
---|---|
132 self.call("unlock") | 132 self.call("unlock") |
133 | 133 |
134 def lookup(self, key): | 134 def lookup(self, key): |
135 d = self.call("lookup", key=key) | 135 d = self.call("lookup", key=key) |
136 success, data = d[:-1].split(" ", 1) | 136 success, data = d[:-1].split(" ", 1) |
137 try: | 137 if int(success): |
138 if int(success): | 138 return bin(data) |
139 return bin(data) | 139 else: |
140 else: | 140 self.repoerror(data) |
141 raise data | |
142 except: | |
143 raise | |
144 raise hg.RepoError("unexpected response '%s'" % (d[:400] + "...")) | |
145 | 141 |
146 def heads(self): | 142 def heads(self): |
147 d = self.call("heads") | 143 d = self.call("heads") |
148 try: | 144 try: |
149 return map(bin, d[:-1].split(" ")) | 145 return map(bin, d[:-1].split(" ")) |