.
This commit is contained in:
parent
a2f2631bdf
commit
3c4f1d103c
@ -369,6 +369,13 @@ func parseGitCommit(data <-chan byte) (commit, error) {
|
||||
func parseTreeEntry(data <-chan byte) (tree_entry, error) {
|
||||
var e tree_entry
|
||||
|
||||
for c:=<-data; c != ' '; c=<-data {
|
||||
e.mode = e.mode * 8 + (c - '0')
|
||||
}
|
||||
for c:=<-data; c != '\x00'; c=<-data {
|
||||
e.name = append(e.name, c)
|
||||
}
|
||||
|
||||
return e, nil
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user