LookUpInodeOp.kernelResponse

geesefs-0-30-9
Aaron Jacobs 2015-07-24 10:55:03 +10:00
parent e226901fc6
commit 99efba2200
1 changed files with 5 additions and 9 deletions

View File

@ -86,16 +86,12 @@ func (o *LookUpInodeOp) ShortDesc() (desc string) {
func (o *LookUpInodeOp) kernelResponse() (msg []byte) {
size := fusekernel.EntryOutSize(fusekernel.Protocol{0, 0})
buf := NewBuffer(size)
buf := fuseshim.NewBuffer(size)
out := (*fusekernel.EntryOut)(buf.Alloc(size))
out.Nodeid = uint64(o.Entry.InodeID)
out.Generation = resp.Generation
out.EntryValid = uint64(resp.EntryValid / time.Second)
out.EntryValidNsec = uint32(resp.EntryValid % time.Second / time.Nanosecond)
out.AttrValid = uint64(resp.Attr.Valid / time.Second)
out.AttrValidNsec = uint32(resp.Attr.Valid % time.Second / time.Nanosecond)
resp.Attr.attr(&out.Attr, r.Header.Conn.proto)
r.respond(buf)
convertChildInodeEntry(&o.Entry, out)
msg = buf
return
}
// Refresh the attributes for an inode whose ID was previously returned in a