[Box Backup-commit] COMMIT r1832 - box/chris/general/bin/bbackupctl

boxbackup-dev at fluffy.co.uk boxbackup-dev at fluffy.co.uk
Fri Sep 14 22:24:23 BST 2007


Author: chris
Date: 2007-09-14 22:24:23 +0100 (Fri, 14 Sep 2007)
New Revision: 1832

Modified:
   box/chris/general/bin/bbackupctl/bbackupctl.cpp
Log:
Pass the command socket name from the configuration to WinNamedPipeStream,
to allow multiple command sockets per system.

Remove unnecessary newlines from log messages.


Modified: box/chris/general/bin/bbackupctl/bbackupctl.cpp
===================================================================
--- box/chris/general/bin/bbackupctl/bbackupctl.cpp	2007-09-14 21:23:23 UTC (rev 1831)
+++ box/chris/general/bin/bbackupctl/bbackupctl.cpp	2007-09-14 21:24:23 UTC (rev 1832)
@@ -145,7 +145,8 @@
 	try
 	{
 #ifdef WIN32
-		connection.Connect(BOX_NAMED_PIPE_NAME);
+		std::string socket = conf.GetKeyValue("CommandSocket");
+		connection.Connect(socket);
 #else
 		connection.Open(Socket::TypeUNIX, conf.GetKeyValue("CommandSocket").c_str());
 #endif
@@ -200,7 +201,7 @@
 			"  UpdateStoreInterval = " << updateStoreInterval << 
 			" seconds\n"
 			"  MinimumFileAge = " << minimumFileAge << " seconds\n"
-			"  MaxUploadWait = " << maxUploadWait << " seconds\n");
+			"  MaxUploadWait = " << maxUploadWait << " seconds");
 	}
 
 	std::string stateLine;
@@ -312,7 +313,7 @@
 				{
 					if (syncIsRunning)
 					{
-						if (!quiet) BOX_INFO("Sync finished.\n");
+						if (!quiet) BOX_INFO("Sync finished.");
 						// Send a quit command to finish nicely
 						connection.Write("quit\n", 5);
 					
@@ -335,7 +336,7 @@
 				{
 					if(!quiet)
 					{
-						BOX_INFO("Succeeded.\n");
+						BOX_INFO("Succeeded.");
 					}
 					finished = true;
 				}




More information about the Boxbackup-commit mailing list