diff --git a/hgext3rd/fbamend/common.py b/hgext3rd/fbamend/common.py --- a/hgext3rd/fbamend/common.py +++ b/hgext3rd/fbamend/common.py @@ -149,7 +149,7 @@ if path in headmf: fctx = head[path] flags = fctx.flags() - mctx = context.memfilectx(repo, fctx.path(), fctx.data(), + mctx = context.memfilectx(repo, ctx, fctx.path(), fctx.data(), islink='l' in flags, isexec='x' in flags, copied=copied.get(path)) diff --git a/hgext3rd/pushrebase.py b/hgext3rd/pushrebase.py --- a/hgext3rd/pushrebase.py +++ b/hgext3rd/pushrebase.py @@ -657,7 +657,7 @@ copied = fctx.renamed() if copied: copied = copied[0] - return context.memfilectx(repo, fctx.path(), fctx.data(), + return context.memfilectx(repo, memctx, fctx.path(), fctx.data(), islink='l' in flags, isexec='x' in flags, copied=copied)