summaryrefslogtreecommitdiff
path: root/bin/bbackupd/BackupClientContext.cpp
diff options
context:
space:
mode:
authorChris Wilson <chris+github@qwirx.com>2008-03-28 22:59:28 +0000
committerChris Wilson <chris+github@qwirx.com>2008-03-28 22:59:28 +0000
commit732bdbdaacb429c94c4120070e531038e3d6f132 (patch)
treeecd16d380ae1d2dcd0d65e089177eb16cca6d47f /bin/bbackupd/BackupClientContext.cpp
parent4fca88ed02c1f0b5208abf2420f73023de54c23e (diff)
Allow configuration of the server port that the client will connect to
(bbackupd and bbackupquery). Redesign ConfigurationVerify to use classes instead of structs. Use port 22011 instead of 2201 during tests, to reduce the chances of conflicting with a running bbstored or other process. Ignore autogen_* in svn:ignore everywhere instead of individual per-file ignores.
Diffstat (limited to 'bin/bbackupd/BackupClientContext.cpp')
-rw-r--r--bin/bbackupd/BackupClientContext.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/bin/bbackupd/BackupClientContext.cpp b/bin/bbackupd/BackupClientContext.cpp
index fd9ff5df..146f7cb8 100644
--- a/bin/bbackupd/BackupClientContext.cpp
+++ b/bin/bbackupd/BackupClientContext.cpp
@@ -44,6 +44,7 @@ BackupClientContext::BackupClientContext
BackupDaemon &rDaemon,
TLSContext &rTLSContext,
const std::string &rHostname,
+ int Port,
int32_t AccountNumber,
bool ExtendedLogging,
bool ExtendedLogToFile,
@@ -52,6 +53,7 @@ BackupClientContext::BackupClientContext
: mrDaemon(rDaemon),
mrTLSContext(rTLSContext),
mHostname(rHostname),
+ mPort(Port),
mAccountNumber(AccountNumber),
mpSocket(0),
mpConnection(0),
@@ -129,7 +131,8 @@ BackupProtocolClient &BackupClientContext::GetConnection()
mHostname << "'...");
// Connect!
- mpSocket->Open(mrTLSContext, Socket::TypeINET, mHostname.c_str(), BOX_PORT_BBSTORED);
+ mpSocket->Open(mrTLSContext, Socket::TypeINET,
+ mHostname.c_str(), mPort);
// And create a procotol object
mpConnection = new BackupProtocolClient(*mpSocket);