Monotone-Parent: a6d78867a3dc3aa8d263e0a0a3afd0a15307c907

Monotone-Revision: 776dc75fed5683da1627715f48714600978e0286

Monotone-Author: wsourdeau@inverse.ca
Monotone-Date: 2010-02-24T21:37:57
Monotone-Branch: ca.inverse.sogo
maint-2.0.2
Wolfgang Sourdeau 2010-02-24 21:37:57 +00:00
parent 1ca9679ba2
commit 639d6cfde5
1 changed files with 14 additions and 6 deletions

View File

@ -5436,7 +5436,7 @@ Index: sope-appserver/NGObjWeb/WOWatchDogApplicationMain.m
#if defined(__CYGWIN32__) || defined(__MINGW32__)
int WOWatchDogApplicationMain
@@ -39,201 +60,875 @@
@@ -39,201 +60,876 @@
#include <time.h>
#include <string.h>
@ -6023,6 +6023,7 @@ Index: sope-appserver/NGObjWeb/WOWatchDogApplicationMain.m
+ [self logWithFormat: @"child spawned with pid %d", childPid];
+ [child setPid: childPid];
+ [child setStatus: WOChildStatusSpawning];
+ [pair[1] setReceiveTimeout: 1.0];
+ [child setControlSocket: pair[1]];
+ [child setLastSpawn: [NSCalendarDate date]];
+ } else {
@ -6473,7 +6474,7 @@ Index: sope-appserver/NGObjWeb/WOWatchDogApplicationMain.m
#if LIB_FOUNDATION_LIBRARY || defined(GS_PASS_ARGUMENTS)
{
extern char **environ;
@@ -241,179 +936,59 @@
@@ -241,179 +937,59 @@
environment:(void*)environ];
}
#endif
@ -6701,7 +6702,7 @@ Index: sope-appserver/NGObjWeb/WOWatchDogApplicationMain.m
}
#endif
@@ -421,8 +996,8 @@
@@ -421,8 +997,8 @@
@interface NSUserDefaults(ServerDefaults)
+ (id)hackInServerDefaults:(NSUserDefaults *)_ud
@ -6712,7 +6713,7 @@ Index: sope-appserver/NGObjWeb/WOWatchDogApplicationMain.m
@end
int WOWatchDogApplicationMainWithServerDefaults
@@ -437,7 +1012,7 @@
@@ -437,7 +1013,7 @@
{
extern char **environ;
[NSProcessInfo initializeWithArguments:(void*)argv count:argc
@ -6721,7 +6722,7 @@ Index: sope-appserver/NGObjWeb/WOWatchDogApplicationMain.m
}
#endif
@@ -446,8 +1021,8 @@
@@ -446,8 +1022,8 @@
ud = [NSUserDefaults standardUserDefaults];
sd = [defClass hackInServerDefaults:ud
@ -6954,7 +6955,14 @@ Index: sope-appserver/NGObjWeb/ChangeLog
===================================================================
--- sope-appserver/NGObjWeb/ChangeLog (revision 1664)
+++ sope-appserver/NGObjWeb/ChangeLog (working copy)
@@ -1,3 +1,177 @@
@@ -1,3 +1,184 @@
+2010-02-24 Wolfgang Sourdeau <wsourdeau@inverse.ca>
+
+ * WOWatchDogApplicationMain.m (_spawnChild:): we set a timeout of
+ 1 second to the parent-side child control socket to avoid hang on
+ status reads when the child dies before the message reaches the
+ parent.
+
+2010-02-18 Wolfgang Sourdeau <wsourdeau@inverse.ca>
+
+ * WOWatchDogApplicationMain.m (-run:argc:argv:): we assign the