1
0
Fork 0

Fix Windows compile issue.

This commit is contained in:
ThorstenB 2012-02-19 22:13:41 +01:00
parent 0ba48793ea
commit 42dab5d81d

View file

@ -86,9 +86,12 @@ usage( const string& prog ) {
" -e transport using external svn client\n" " -e transport using external svn client\n"
" -p <port> listen on UDP port [default: 5501]\n" " -p <port> listen on UDP port [default: 5501]\n"
" -s <source> source base [default: '']\n" " -s <source> source base [default: '']\n"
#ifndef _MSC_VER
" -pid <pidfile> write PID to file\n" " -pid <pidfile> write PID to file\n"
#endif
" -v be more verbose\n"; " -v be more verbose\n";
#ifndef _MSC_VER
cout << "\n" cout << "\n"
"Example:\n" "Example:\n"
" pid=$(cat $pidfile 2>/dev/null)\n" " pid=$(cat $pidfile 2>/dev/null)\n"
@ -98,6 +101,7 @@ usage( const string& prog ) {
" nice /games/sport/fgs/utils/TerraSync/terrasync \\\n" " nice /games/sport/fgs/utils/TerraSync/terrasync \\\n"
" -v -pid $pidfile -S -p 5500 -d /games/orig/terrasync &\n" " -v -pid $pidfile -S -p 5500 -d /games/orig/terrasync &\n"
" fi\n"; " fi\n";
#endif
} }
/** Signal handler for termination requests (Ctrl-C) */ /** Signal handler for termination requests (Ctrl-C) */
@ -338,6 +342,7 @@ int main( int argc, char **argv )
if (verbose) if (verbose)
sglog().setLogLevels( SG_ALL, SG_INFO); sglog().setLogLevels( SG_ALL, SG_INFO);
#ifndef _MSC_VER
// create PID file // create PID file
if (*pidfn) if (*pidfn)
{ {
@ -352,6 +357,7 @@ int main( int argc, char **argv )
pidstream << getpid() << endl; pidstream << getpid() << endl;
pidstream.close(); pidstream.close();
} }
#endif
// install signal handlers // install signal handlers
for (int* sigp=termination_triggering_signals; *sigp; sigp++) for (int* sigp=termination_triggering_signals; *sigp; sigp++)