diff options
author | Brad Fitzpatrick <bradfitz@golang.org> | 2014-09-23 14:26:20 -0700 |
---|---|---|
committer | Brad Fitzpatrick <bradfitz@golang.org> | 2014-09-23 14:26:20 -0700 |
commit | a799331ee58770a1ad3d82eb70bb52e54de94b57 (patch) | |
tree | 1309287167a62c190f37c81724ae0304f9d1adc9 | |
parent | c54573c43c437dd46ecc44ea3f9c63209f80237d (diff) | |
download | go-a799331ee58770a1ad3d82eb70bb52e54de94b57.tar.gz |
os: fix another case where RemoveAll should return nil
This hopefully fixes issue 8793.
Fixes Issue 8793
LGTM=iant
R=rsc, iant
CC=golang-codereviews
https://codereview.appspot.com/150860046
-rw-r--r-- | src/os/path.go | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/os/path.go b/src/os/path.go index 6cc69403b..b1a90b3e5 100644 --- a/src/os/path.go +++ b/src/os/path.go @@ -86,6 +86,9 @@ func RemoveAll(path string) error { // Directory. fd, err := Open(path) if err != nil { + if IsNotExist(err) { + return nil + } return err } |