mercurial/merge.py
changeset 4005 656e06eebda7
parent 3893 6b4127c7d52a
child 4006 67982d3ee76c
equal deleted inserted replaced
4004:c83c35f2f4e2 4005:656e06eebda7
    18     """
    18     """
    19 
    19 
    20     def temp(prefix, ctx):
    20     def temp(prefix, ctx):
    21         pre = "%s~%s." % (os.path.basename(ctx.path()), prefix)
    21         pre = "%s~%s." % (os.path.basename(ctx.path()), prefix)
    22         (fd, name) = tempfile.mkstemp(prefix=pre)
    22         (fd, name) = tempfile.mkstemp(prefix=pre)
       
    23         data = repo.wwritedata(ctx.path(), ctx.data())
    23         f = os.fdopen(fd, "wb")
    24         f = os.fdopen(fd, "wb")
    24         repo.wwrite(ctx.path(), ctx.data(), f)
    25         f.write(data)
    25         f.close()
    26         f.close()
    26         return name
    27         return name
    27 
    28 
    28     fcm = wctx.filectx(fw)
    29     fcm = wctx.filectx(fw)
    29     fco = mctx.filectx(fo)
    30     fco = mctx.filectx(fo)