aboutsummaryrefslogtreecommitdiffstats
path: root/ethutil/path.go
diff options
context:
space:
mode:
authorobscuren <geffobscura@gmail.com>2014-09-23 01:34:31 +0800
committerobscuren <geffobscura@gmail.com>2014-09-23 01:34:31 +0800
commitce149d2733bd55e8e9b16dd4b60b6bad17c3d7d9 (patch)
treeac183aa3312a4589cb3e4995cc103cfa58ef95da /ethutil/path.go
parent8ef17c2fb138ae254a0cc7ac509a7ab1177ee4ac (diff)
parent7d08e4f7d14600ee4ed38fc9d435e9c2e0e0fdac (diff)
downloaddexon-ce149d2733bd55e8e9b16dd4b60b6bad17c3d7d9.tar
dexon-ce149d2733bd55e8e9b16dd4b60b6bad17c3d7d9.tar.gz
dexon-ce149d2733bd55e8e9b16dd4b60b6bad17c3d7d9.tar.bz2
dexon-ce149d2733bd55e8e9b16dd4b60b6bad17c3d7d9.tar.lz
dexon-ce149d2733bd55e8e9b16dd4b60b6bad17c3d7d9.tar.xz
dexon-ce149d2733bd55e8e9b16dd4b60b6bad17c3d7d9.tar.zst
dexon-ce149d2733bd55e8e9b16dd4b60b6bad17c3d7d9.zip
Merge branch 'release/0.6.5'
Diffstat (limited to 'ethutil/path.go')
-rw-r--r--ethutil/path.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/ethutil/path.go b/ethutil/path.go
index 27022bcfa..cfbc38950 100644
--- a/ethutil/path.go
+++ b/ethutil/path.go
@@ -45,7 +45,7 @@ func ReadAllFile(filePath string) (string, error) {
}
func WriteFile(filePath string, content []byte) error {
- fh, err := os.OpenFile(filePath, os.O_RDWR|os.O_CREATE, os.ModePerm)
+ fh, err := os.OpenFile(filePath, os.O_TRUNC|os.O_RDWR|os.O_CREATE, os.ModePerm)
if err != nil {
return err
}