diff options
author | Steve Slaven <bpk@hoopajoo.net> | 2009-11-02 23:59:19 (GMT) |
---|---|---|
committer | Steve Slaven <bpk@hoopajoo.net> | 2009-11-02 23:59:19 (GMT) |
commit | 68af6dc389055d590ba7746aea283b4e36ee68d0 (patch) | |
tree | aafdee5005d9927179f424c04107849809e63d46 | |
parent | 5ffcb57273d6476868397d215567eca6e48f9963 (diff) | |
download | fusearchive-68af6dc389055d590ba7746aea283b4e36ee68d0.zip fusearchive-68af6dc389055d590ba7746aea283b4e36ee68d0.tar.gz fusearchive-68af6dc389055d590ba7746aea283b4e36ee68d0.tar.bz2 |
Handle truncate
-rw-r--r-- | FuseArchive/ChunkBuffer.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/FuseArchive/ChunkBuffer.py b/FuseArchive/ChunkBuffer.py index 7b6beee..89d468e 100644 --- a/FuseArchive/ChunkBuffer.py +++ b/FuseArchive/ChunkBuffer.py @@ -27,6 +27,10 @@ class ChunkBuffer: return l + def truncate( self, l ): + s = ''.join( self.chunk ) + self.chunk = [ s[ :l ] ] + def _simplify( self ): logging.debug( "Simplify!" ) self.chunk = [ ''.join( self.chunk ) ] |