[Box Backup-commit] COMMIT r1346 - box/chris/general/lib/common
boxbackup-dev at fluffy.co.uk
boxbackup-dev at fluffy.co.uk
Sun Mar 4 20:54:43 GMT 2007
Author: chris
Date: 2007-03-04 20:54:42 +0000 (Sun, 04 Mar 2007)
New Revision: 1346
Modified:
box/chris/general/lib/common/Test.h
Log:
Don't use an imaginary PID to check whether the process exists on Unix
Modified: box/chris/general/lib/common/Test.h
===================================================================
--- box/chris/general/lib/common/Test.h 2007-03-04 20:39:50 UTC (rev 1345)
+++ box/chris/general/lib/common/Test.h 2007-03-04 20:54:42 UTC (rev 1346)
@@ -224,8 +224,6 @@
#endif // WIN32
- int pid = -1;
-
#ifdef WIN32
// on other platforms there is no other way to get
// the PID, so a NULL pidFile doesn't make sense.
@@ -249,12 +247,10 @@
#ifdef WIN32
if (!ServerIsAlive((int)procInfo.dwProcessId))
- #else
- if (!ServerIsAlive(pid))
- #endif
{
break;
}
+ #endif
::fprintf(stdout, ".");
::fflush(stdout);
@@ -285,7 +281,7 @@
}
// read pid file
- pid = ReadPidFile(pidFile);
+ int pid = ReadPidFile(pidFile);
#ifdef WIN32
// On Win32 we can check whether the PID in the pidFile matches
More information about the Boxbackup-commit
mailing list