diff options
| author | chrislu <chris.lu@gmail.com> | 2021-12-20 01:11:43 -0800 |
|---|---|---|
| committer | chrislu <chris.lu@gmail.com> | 2021-12-20 01:11:43 -0800 |
| commit | 4fd29dad868916d39d27b6d4a5184e73cc254ebb (patch) | |
| tree | 475dcda39c5f53316cfe7d0b410598659ec717e4 /weed/filesys/filehandle.go | |
| parent | bc96682760f5fbbb198210cdc7354d4451906ed2 (diff) | |
| download | seaweedfs-4fd29dad868916d39d27b6d4a5184e73cc254ebb.tar.xz seaweedfs-4fd29dad868916d39d27b6d4a5184e73cc254ebb.zip | |
remove writeOnly flag
Diffstat (limited to 'weed/filesys/filehandle.go')
| -rw-r--r-- | weed/filesys/filehandle.go | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/weed/filesys/filehandle.go b/weed/filesys/filehandle.go index 6054fb3c4..232d28667 100644 --- a/weed/filesys/filehandle.go +++ b/weed/filesys/filehandle.go @@ -37,11 +37,11 @@ type FileHandle struct { isDeleted bool } -func newFileHandle(file *File, uid, gid uint32, writeOnly bool) *FileHandle { +func newFileHandle(file *File, uid, gid uint32) *FileHandle { fh := &FileHandle{ f: file, // dirtyPages: newContinuousDirtyPages(file, writeOnly), - dirtyPages: newTempFileDirtyPages(file, writeOnly), + dirtyPages: newTempFileDirtyPages(file), Uid: uid, Gid: gid, } @@ -305,7 +305,7 @@ func (fh *FileHandle) doFlush(ctx context.Context, header fuse.Header) error { manifestChunks, nonManifestChunks := filer.SeparateManifestChunks(entry.Chunks) chunks, _ := filer.CompactFileChunks(fh.f.wfs.LookupFn(), nonManifestChunks) - chunks, manifestErr := filer.MaybeManifestize(fh.f.wfs.saveDataAsChunk(fh.f.fullpath(), fh.dirtyPages.GetWriteOnly()), chunks) + chunks, manifestErr := filer.MaybeManifestize(fh.f.wfs.saveDataAsChunk(fh.f.fullpath()), chunks) if manifestErr != nil { // not good, but should be ok glog.V(0).Infof("MaybeManifestize: %v", manifestErr) |
