summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAdam Manzanares <nmtadam@gmail.com>2013-05-10 10:55:30 -0700
committerAdam Manzanares <nmtadam@gmail.com>2013-05-10 10:55:30 -0700
commit399d278e603d9b47f92136b9bd7679978d3b2535 (patch)
treef193ef154360b8fd81a7d1aafccc86e4241351e4
parent27d76e442d96139f9038d83d23275877fa3d3c9b (diff)
downloadfusepy-399d278e603d9b47f92136b9bd7679978d3b2535.tar.gz
loopback example update
I was looking over the loopback example and I noticed that the create method was not truncating the file.
-rwxr-xr-xexamples/loopback.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/examples/loopback.py b/examples/loopback.py
index a7b8275..b957a10 100755
--- a/examples/loopback.py
+++ b/examples/loopback.py
@@ -28,7 +28,7 @@ class Loopback(LoggingMixIn, Operations):
chown = os.chown
def create(self, path, mode):
- return os.open(path, os.O_WRONLY | os.O_CREAT, mode)
+ return os.open(path, os.O_WRONLY | os.O_CREAT | os.O_TRUNC, mode)
def flush(self, path, fh):
return os.fsync(fh)