Patchwork [06,of,10] commands: use cg?unpacker.apply() instead of changegroup.addchangegroup()

login
register
mail settings
Submitter Augie Fackler
Date Oct. 14, 2015, 5:34 p.m.
Message ID <1b1ed2a1f9fd3601bb7d.1444844071@augie-macbookair2.roam.corp.google.com>
Download mbox | patch
Permalink /patch/11058/
State Accepted
Headers show

Comments

Augie Fackler - Oct. 14, 2015, 5:34 p.m.
# HG changeset patch
# User Augie Fackler <augie@google.com>
# Date 1444770732 14400
#      Tue Oct 13 17:12:12 2015 -0400
# Node ID 1b1ed2a1f9fd3601bb7d67af067b6aa66ef5ac49
# Parent  6fd04cbc7f36b6d3aad99d85db12a97f90919a46
commands: use cg?unpacker.apply() instead of changegroup.addchangegroup()

Patch

diff --git a/mercurial/commands.py b/mercurial/commands.py
--- a/mercurial/commands.py
+++ b/mercurial/commands.py
@@ -6515,8 +6515,7 @@  def unbundle(ui, repo, fname1, *fnames, 
                            for r in op.records['changegroup']]
                 modheads = changegroup.combineresults(changes)
             else:
-                modheads = changegroup.addchangegroup(repo, gen, 'unbundle',
-                                                      'bundle:' + fname)
+                modheads = gen.apply(repo, 'unbundle', 'bundle:' + fname)
     finally:
         lock.release()