# HG changeset patch # User Pierre-Yves David # Date 2017-07-02 02:26:34 # Node ID 761ccfeff8b121ba646fc64bf1d478fa478b9baf # Parent 15e9cbe6ae49113d4a88631157d77f81483e4262 streamclone: stop using 'vfs.mustaudit = False' Now that each call disable the auditing on its own, we can safely drop this the mustaudit usage. No other code is modified. diff --git a/mercurial/streamclone.py b/mercurial/streamclone.py --- a/mercurial/streamclone.py +++ b/mercurial/streamclone.py @@ -213,26 +213,21 @@ def generatev1(repo): (len(entries), total_bytes)) svfs = repo.svfs - oldaudit = svfs.mustaudit debugflag = repo.ui.debugflag - svfs.mustaudit = False def emitrevlogdata(): - try: - for name, size in entries: - if debugflag: - repo.ui.debug('sending %s (%d bytes)\n' % (name, size)) - # partially encode name over the wire for backwards compat - yield '%s\0%d\n' % (store.encodedir(name), size) - if size <= 65536: - with svfs(name, 'rb', auditpath=False) as fp: - yield fp.read(size) - else: - data = svfs(name, auditpath=False) - for chunk in util.filechunkiter(data, limit=size): - yield chunk - finally: - svfs.mustaudit = oldaudit + for name, size in entries: + if debugflag: + repo.ui.debug('sending %s (%d bytes)\n' % (name, size)) + # partially encode name over the wire for backwards compat + yield '%s\0%d\n' % (store.encodedir(name), size) + if size <= 65536: + with svfs(name, 'rb', auditpath=False) as fp: + yield fp.read(size) + else: + data = svfs(name, auditpath=False) + for chunk in util.filechunkiter(data, limit=size): + yield chunk return len(entries), total_bytes, emitrevlogdata()