diff options
-rwxr-xr-x | fusearchive.py | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/fusearchive.py b/fusearchive.py index ccfb384..65183b7 100755 --- a/fusearchive.py +++ b/fusearchive.py @@ -77,7 +77,7 @@ def _save_chunk_fs( chunk ): return( [ 0, 0 ] ) logging.debug( "Begin save_chunk, length: " + str( len( chunk ) ) ) - if debug_level > 4: + if logging.getLogger().getEffectiveLevel() == logging.DEBUG: logging.debug( "Chunk: " + str( chunk ) ) # Save this hash string, similar to the backuppc algo @@ -140,7 +140,7 @@ def _save_chunk_zip( chunk ): return( [ 0, 0 ] ) logging.debug( "Begin save_chunk, length: " + str( len( chunk ) ) ) - if debug_level > 4: + if logging.getLogger().getEffectiveLevel() == logging.DEBUG: logging.debug( "Chunk: " + str( chunk ) ) # Save this hash string, similar to the backuppc algo @@ -225,7 +225,7 @@ def _load_chunk_fs( key ): else: raise IOError - if debug_level > 4: + if logging.getLogger().getEffectiveLevel() == logging.DEBUG: logging.debug( "Load-Chunk: " + str( chunk ) ) return chunk @@ -257,7 +257,7 @@ def _load_chunk_zip( key ): z.close() raise IOError - if debug_level > 4: + if logging.getLogger().getEffectiveLevel() == logging.DEBUG: logging.debug( "Load-Chunk: " + str( chunk ) ) z.close() @@ -664,7 +664,7 @@ class FuseArchive(Fuse): logging.debug( " chunk offset: " + str(rest) ) - if debug_level > 4: + if logging.getLogger().getEffectiveLevel() == logging.DEBUG: logging.debug( "Pre-Buf: " + str(buf) ) logging.debug( "Pre-Chunk: " + str(self.chunk) ) @@ -677,7 +677,7 @@ class FuseArchive(Fuse): buf[ buf_offset:(buf_offset+this_len) ] + \ self.chunk[ (rest + this_len): ] - if debug_level > 4: + if logging.getLogger().getEffectiveLevel() == logging.DEBUG: logging.debug( "Post-Buf: " + str(buf) ) logging.debug( "Post-Chunk: " + str(self.chunk) ) @@ -781,7 +781,7 @@ class FuseArchive(Fuse): self._load_chunk( 0 ) - pdb.set_trace() + #pdb.set_trace() if need_chunks == 0: logging.debug( "Creating 0 chunk file" ) self.chunks = [] |