diff options
| author | Sebastian Lackner | 2018-12-26 22:22:40 +0100 | 
|---|---|---|
| committer | rfjakob | 2018-12-27 15:18:03 +0100 | 
| commit | 4c2ff26457471cd36b25c29fb3f982b27002ce3c (patch) | |
| tree | 42be76781d23a51f85a1c4ca13e0728824d07f0a | |
| parent | 1ced0b192e6abcb047af0b9f11dfaf63052598c4 (diff) | |
fusefrontend: Remove unnecessary check in doRead function.
The same condition is already checked a few lines above, and 'err' is not
changed inbetween.
| -rw-r--r-- | internal/fusefrontend/file.go | 6 | 
1 files changed, 2 insertions, 4 deletions
| diff --git a/internal/fusefrontend/file.go b/internal/fusefrontend/file.go index 9230bed..04ae526 100644 --- a/internal/fusefrontend/file.go +++ b/internal/fusefrontend/file.go @@ -162,10 +162,8 @@ func (f *File) doRead(dst []byte, off uint64, length uint64) ([]byte, fuse.Statu  				// Empty file  				return nil, fuse.OK  			} -			if err != nil { -				tlog.Warn.Printf("doRead %d: corrupt header: %v", f.qIno.Ino, err) -				return nil, fuse.EIO -			} +			tlog.Warn.Printf("doRead %d: corrupt header: %v", f.qIno.Ino, err) +			return nil, fuse.EIO  		}  		// Save into the file table  		f.fileTableEntry.ID = fileID | 
