Fix index writing
This commit is contained in:
parent
dbe3bca439
commit
ff78648324
@ -814,7 +814,7 @@ class GitIndexEntry (object):
|
|||||||
# Group ID of the owner
|
# Group ID of the owner
|
||||||
self.gid = gid
|
self.gid = gid
|
||||||
# Size of this object, in bytes
|
# Size of this object, in bytes
|
||||||
self.fize = fsize
|
self.fsize = fsize
|
||||||
# The object's SHA
|
# The object's SHA
|
||||||
self.sha = sha
|
self.sha = sha
|
||||||
self.flag_assume_valid = flag_assume_valid
|
self.flag_assume_valid = flag_assume_valid
|
||||||
@ -1223,6 +1223,9 @@ def index_write(repo, index):
|
|||||||
f.write(mode.to_bytes(4, "big"))
|
f.write(mode.to_bytes(4, "big"))
|
||||||
|
|
||||||
f.write(e.uid.to_bytes(4, "big"))
|
f.write(e.uid.to_bytes(4, "big"))
|
||||||
|
f.write(e.gid.to_bytes(4, "big"))
|
||||||
|
|
||||||
|
f.write(e.fsize.to_bytes(4, "big"))
|
||||||
# FIXME: Convert back to int.
|
# FIXME: Convert back to int.
|
||||||
f.write(int(e.sha, 16).to_bytes(20, "big"))
|
f.write(int(e.sha, 16).to_bytes(20, "big"))
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user