summaryrefslogtreecommitdiff
path: root/lib/backupstore/BackupProtocol.h
diff options
context:
space:
mode:
Diffstat (limited to 'lib/backupstore/BackupProtocol.h')
-rw-r--r--lib/backupstore/BackupProtocol.h13
1 files changed, 12 insertions, 1 deletions
diff --git a/lib/backupstore/BackupProtocol.h b/lib/backupstore/BackupProtocol.h
index 561c6ccd..43f3e162 100644
--- a/lib/backupstore/BackupProtocol.h
+++ b/lib/backupstore/BackupProtocol.h
@@ -26,6 +26,8 @@ class BackupProtocolLocal2 : public BackupProtocolLocal
{
private:
BackupStoreContext mContext;
+ int32_t mAccountNumber;
+ bool mReadOnly;
public:
BackupProtocolLocal2(int32_t AccountNumber,
@@ -36,7 +38,9 @@ public:
// touch the Context, because it's not initialised yet!
: BackupProtocolLocal(mContext),
mContext(AccountNumber, (HousekeepingInterface *)NULL,
- ConnectionDetails)
+ ConnectionDetails),
+ mAccountNumber(AccountNumber),
+ mReadOnly(ReadOnly)
{
mContext.SetClientHasAccount(AccountRootDir, DiscSetNumber);
QueryVersion(BACKUP_STORE_SERVER_VERSION);
@@ -52,6 +56,13 @@ public:
mContext.ReleaseWriteLock();
return finished;
}
+
+ void Reopen()
+ {
+ QueryVersion(BACKUP_STORE_SERVER_VERSION);
+ QueryLogin(mAccountNumber,
+ mReadOnly ? BackupProtocolLogin::Flags_ReadOnly : 0);
+ }
};
#endif // BACKUPPROTOCOL__H