diff options
author | Niall Sheridan <nsheridan@gmail.com> | 2017-02-12 22:24:33 +0000 |
---|---|---|
committer | Niall Sheridan <nsheridan@gmail.com> | 2017-02-12 22:24:33 +0000 |
commit | ba4840c52becf73c2749c9ef0f2f09ed0b9d5c7f (patch) | |
tree | 61b839884d66c9dd8269e26117aa4e4c995ad119 /vendor/github.com/spf13/afero/mem/file.go | |
parent | 6e00d0000e54f21a4a393e67fd914bda4d394f4a (diff) |
Update dependencies
Diffstat (limited to 'vendor/github.com/spf13/afero/mem/file.go')
-rw-r--r-- | vendor/github.com/spf13/afero/mem/file.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/vendor/github.com/spf13/afero/mem/file.go b/vendor/github.com/spf13/afero/mem/file.go index 3c1e09a..e41e012 100644 --- a/vendor/github.com/spf13/afero/mem/file.go +++ b/vendor/github.com/spf13/afero/mem/file.go @@ -186,7 +186,7 @@ func (f *File) Truncate(size int64) error { return ErrFileClosed } if f.readOnly { - return &os.PathError{"truncate", f.fileData.name, errors.New("file handle is read only")} + return &os.PathError{Op: "truncate", Path: f.fileData.name, Err: errors.New("file handle is read only")} } if size < 0 { return ErrOutOfRange @@ -218,7 +218,7 @@ func (f *File) Seek(offset int64, whence int) (int64, error) { func (f *File) Write(b []byte) (n int, err error) { if f.readOnly { - return 0, &os.PathError{"write", f.fileData.name, errors.New("file handle is read only")} + return 0, &os.PathError{Op: "write", Path: f.fileData.name, Err: errors.New("file handle is read only")} } n = len(b) cur := atomic.LoadInt64(&f.at) |