[Zodb-checkins] CVS: StandaloneZODB/ZEO - StorageServer.py:1.21.4.18

Jeremy Hylton jeremy@zope.com
Tue, 8 Jan 2002 13:12:12 -0500


Update of /cvs-repository/StandaloneZODB/ZEO
In directory cvs.zope.org:/tmp/cvs-serv1744

Modified Files:
      Tag: ZEO-ZRPC-Dev
	StorageServer.py 
Log Message:
Raise ReadOnlyError in register() if storage is read-only and client isn't.


=== StandaloneZODB/ZEO/StorageServer.py 1.21.4.17 => 1.21.4.18 ===
             raise ValueError, "unknown storage: %s" % storage_id
 
+        if not read_only and storage.isReadOnly():
+            raise POSException.ReadOnlyError()
+
         self.__storage_id = storage_id
         self.__storage = storage
         self.setup_delegation()