]> git.rkrishnan.org Git - tahoe-lafs/tahoe-lafs.git/commitdiff
Correct off-by-one in maximum-immutable-share-size for old servers. fixes #1781
authorDavid-Sarah Hopwood <david-sarah@jacaranda.org>
Sat, 23 Mar 2013 03:10:50 +0000 (03:10 +0000)
committerDavid-Sarah Hopwood <david-sarah@jacaranda.org>
Sat, 23 Mar 2013 03:10:50 +0000 (03:10 +0000)
Signed-off-by: David-Sarah Hopwood <david-sarah@jacaranda.org>
src/allmydata/storage_client.py
src/allmydata/test/test_upload.py

index a0cd7ddad810dab97be2c8fffb77654b96d08416..39753e0cb79396dceb16f1b6c1cc2d16f6110794 100644 (file)
@@ -178,7 +178,7 @@ class NativeStorageServer:
 
     VERSION_DEFAULTS = {
         "http://allmydata.org/tahoe/protocols/storage/v1" :
-        { "maximum-immutable-share-size": 2**32,
+        { "maximum-immutable-share-size": 2**32 - 1,
           "maximum-mutable-share-size": 2*1000*1000*1000, # maximum prior to v1.9.2
           "tolerates-immutable-read-overrun": False,
           "delete-mutable-shares-with-zero-length-writev": False,
index 20524ef06ea6e7ddd24dcc6c07f792f53354df15..7d65926c7513bacc58e19c380db8e6c7c3c8c6bf 100644 (file)
@@ -106,7 +106,7 @@ class FakeStorageServer:
         self.allocated = []
         self.queries = 0
         self.version = { "http://allmydata.org/tahoe/protocols/storage/v1" :
-                         { "maximum-immutable-share-size": 2**32 },
+                         { "maximum-immutable-share-size": 2**32 - 1 },
                          "application-version": str(allmydata.__full_version__),
                          }
         if mode == "small":