Show More
@@ -84,11 +84,8 b' def update(repo, node, branchmerge=False' | |||
|
84 | 84 | m2n = repo.changelog.read(p2)[0] |
|
85 | 85 | man = repo.manifest.ancestor(m1n, m2n) |
|
86 | 86 | m1 = repo.manifest.read(m1n) |
|
87 | mf1 = repo.manifest.readflags(m1n) | |
|
88 | 87 | m2 = repo.manifest.read(m2n).copy() |
|
89 | mf2 = repo.manifest.readflags(m2n) | |
|
90 | 88 | ma = repo.manifest.read(man) |
|
91 | mfa = repo.manifest.readflags(man) | |
|
92 | 89 | |
|
93 | 90 | if not forcemerge and not overwrite: |
|
94 | 91 | for f in unknown: |
@@ -113,12 +110,11 b' def update(repo, node, branchmerge=False' | |||
|
113 | 110 | |
|
114 | 111 | # construct a working dir manifest |
|
115 | 112 | mw = m1.copy() |
|
116 | mfw = mf1.copy() | |
|
117 | 113 | umap = dict.fromkeys(unknown) |
|
118 | 114 | |
|
119 | 115 | for f in added + modified + unknown: |
|
120 | 116 | mw[f] = "" |
|
121 |
m |
|
|
117 | mw.set(f, util.is_exec(repo.wjoin(f), mw.execf(f))) | |
|
122 | 118 | |
|
123 | 119 | for f in deleted + removed: |
|
124 | 120 | if f in mw: |
@@ -155,7 +151,7 b' def update(repo, node, branchmerge=False' | |||
|
155 | 151 | repo.ui.debug(_(" %s versions differ, resolve\n") % f) |
|
156 | 152 | # merge executable bits |
|
157 | 153 | # "if we changed or they changed, change in merge" |
|
158 |
a, b, c = m |
|
|
154 | a, b, c = ma.execf(f), mw.execf(f), m2.execf(f) | |
|
159 | 155 | mode = ((a^b) | (a^c)) ^ a |
|
160 | 156 | merge[f] = (mode, m1.get(f, nullid), m2[f]) |
|
161 | 157 | s = 1 |
@@ -171,12 +167,12 b' def update(repo, node, branchmerge=False' | |||
|
171 | 167 | # we need to reset the dirstate if the file was added |
|
172 | 168 | get[f] = (m2.execf(f), m2[f]) |
|
173 | 169 | |
|
174 |
if not s and m |
|
|
170 | if not s and mw.execf(f) != m2.execf(f): | |
|
175 | 171 | if overwrite: |
|
176 | 172 | repo.ui.debug(_(" updating permissions for %s\n") % f) |
|
177 |
util.set_exec(repo.wjoin(f), m |
|
|
173 | util.set_exec(repo.wjoin(f), m2.execf(f)) | |
|
178 | 174 | else: |
|
179 |
a, b, c = m |
|
|
175 | a, b, c = ma.execf(f), mw.execf(f), m2.execf(f) | |
|
180 | 176 | mode = ((a^b) | (a^c)) ^ a |
|
181 | 177 | if mode != b: |
|
182 | 178 | repo.ui.debug(_(" updating permissions for %s\n") |
General Comments 0
You need to be logged in to leave comments.
Login now