Przeglądaj źródła

remove max_chunk_size (unused)

Thomas Waldmann 4 lat temu
rodzic
commit
3b9798cffc
2 zmienionych plików z 1 dodań i 10 usunięć
  1. 1 1
      src/borg/archive.py
  2. 0 9
      src/borg/chunker.pyx

+ 1 - 1
src/borg/archive.py

@@ -19,7 +19,7 @@ from .logger import create_logger
 logger = create_logger()
 
 from . import xattr
-from .chunker import get_chunker, max_chunk_size, Chunk, cached_hash, zeros
+from .chunker import get_chunker, Chunk, cached_hash, zeros
 from .cache import ChunkListEntry
 from .crypto.key import key_factory
 from .compress import Compressor, CompressionSpec

+ 0 - 9
src/borg/chunker.pyx

@@ -308,15 +308,6 @@ def get_chunker(algo, *params, **kw):
     raise TypeError('unsupported chunker algo %r' % algo)
 
 
-def max_chunk_size(algo, *params):
-    # see also parseformat.ChunkerParams return values
-    if algo == 'buzhash':
-        return 1 << params[1]
-    if algo == 'fixed':
-        return max(params[0], params[1])
-    raise TypeError('unsupported chunker algo %r' % algo)
-
-
 def buzhash(data, unsigned long seed):
     cdef uint32_t *table
     cdef uint32_t sum