summaryrefslogtreecommitdiff
path: root/index.go
diff options
context:
space:
mode:
authorRyan Dahl <[email protected]>2014-10-20 11:53:10 -0400
committerRyan Dahl <[email protected]>2014-10-20 11:58:55 -0400
commit5539137e9a6da3276bc83ef47bbebca8bab56856 (patch)
treeea4eadbcd888d1fced7d8f83a368041e5f8f492d /index.go
parent3b7cc1e97e62cf240f93a08983a0dc18bd31c54c (diff)
Use Filemode type in TreeEntry and IndexEntry
Fixes #121
Diffstat (limited to 'index.go')
-rw-r--r--index.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/index.go b/index.go
index b1542d5..289239d 100644
--- a/index.go
+++ b/index.go
@@ -19,7 +19,7 @@ type Index struct {
type IndexEntry struct {
Ctime time.Time
Mtime time.Time
- Mode uint
+ Mode Filemode
Uid uint
Gid uint
Size uint
@@ -34,7 +34,7 @@ func newIndexEntryFromC(entry *C.git_index_entry) *IndexEntry {
return &IndexEntry{
time.Unix(int64(entry.ctime.seconds), int64(entry.ctime.nanoseconds)),
time.Unix(int64(entry.mtime.seconds), int64(entry.mtime.nanoseconds)),
- uint(entry.mode),
+ Filemode(entry.mode),
uint(entry.uid),
uint(entry.gid),
uint(entry.file_size),