diff options
author | Jakob Unterwurzacher | 2017-06-30 23:11:38 +0200 |
---|---|---|
committer | Jakob Unterwurzacher | 2017-06-30 23:11:38 +0200 |
commit | 06398e82d91c81c618bfa6a481c0e9070847c909 (patch) | |
tree | 7179445982d09f79843f035557e8cd8eb8d84c2c /internal/fusefrontend/file_allocate_truncate.go | |
parent | 2932a285aa2e8f6ef7cdd8b3c0387438dcb96015 (diff) |
fusefrontend: Read: use provided buffer
This will allow us to return internal buffers to a pool.
Diffstat (limited to 'internal/fusefrontend/file_allocate_truncate.go')
-rw-r--r-- | internal/fusefrontend/file_allocate_truncate.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/internal/fusefrontend/file_allocate_truncate.go b/internal/fusefrontend/file_allocate_truncate.go index 85ed11c..86aee8e 100644 --- a/internal/fusefrontend/file_allocate_truncate.go +++ b/internal/fusefrontend/file_allocate_truncate.go @@ -144,7 +144,7 @@ func (f *file) Truncate(newSize uint64) fuse.Status { var data []byte if lastBlockLen > 0 { var status fuse.Status - data, status = f.doRead(plainOff, lastBlockLen) + data, status = f.doRead(nil, plainOff, lastBlockLen) if status != fuse.OK { tlog.Warn.Printf("Truncate: shrink doRead returned error: %v", err) return status |