comparison mercurial/patch.py @ 8396:d7a77ad9bcce

patch: copy copies dict before changing it (issue1651)
author Matt Mackall <mpm@selenic.com>
date Thu, 14 May 2009 13:20:40 -0500
parents 46293a0c7e9f
children 88f317e7d280
comparison
equal deleted inserted replaced
8395:475552c03496 8396:d7a77ad9bcce
1234 hexfunc = repo.ui.debugflag and hex or short 1234 hexfunc = repo.ui.debugflag and hex or short
1235 r = [hexfunc(node) for node in [node1, node2] if node] 1235 r = [hexfunc(node) for node in [node1, node2] if node]
1236 1236
1237 if opts.git: 1237 if opts.git:
1238 copy, diverge = copies.copies(repo, ctx1, ctx2, repo[nullid]) 1238 copy, diverge = copies.copies(repo, ctx1, ctx2, repo[nullid])
1239 copy = copy.copy()
1239 for k, v in copy.items(): 1240 for k, v in copy.items():
1240 copy[v] = k 1241 copy[v] = k
1241 1242
1242 gone = {} 1243 gone = {}
1243 gitmode = {'l': '120000', 'x': '100755', '': '100644'} 1244 gitmode = {'l': '120000', 'x': '100755', '': '100644'}