Mercurial > public > mercurial-scm > hg
diff mercurial/hgweb/protocol.py @ 6925:87abfefafe02
make streamclone.stream_out() a generator
author | Dirkjan Ochtman <dirkjan@ochtman.nl> |
---|---|
date | Fri, 15 Aug 2008 13:25:57 +0200 |
parents | c228ae4bc89c |
children | 57b954d8d003 |
line wrap: on
line diff
--- a/mercurial/hgweb/protocol.py Tue Jul 22 18:21:37 2008 +0200 +++ b/mercurial/hgweb/protocol.py Fri Aug 15 13:25:57 2008 +0200 @@ -193,5 +193,8 @@ def stream_out(repo, req): req.respond(HTTP_OK, HGTYPE) - streamclone.stream_out(repo, req, untrusted=True) - return [] + try: + for chunk in streamclone.stream_out(repo, untrusted=True): + yield chunk + except streamclone.StreamException, inst: + yield str(inst)