From: miker Date: Fri, 29 Jun 2007 14:07:01 +0000 (+0000) Subject: test for failed forker creation before touching struct members X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=85522b846058247e583a96b191f2d9de130ee770;p=opensrf%2Fbjwebb.git test for failed forker creation before touching struct members git-svn-id: svn://svn.open-ils.org/OpenSRF/trunk@985 9efc2488-bf62-4759-914b-345cdb29e865 --- diff --git a/src/libopensrf/osrf_prefork.c b/src/libopensrf/osrf_prefork.c index 01a97cc..36b203c 100644 --- a/src/libopensrf/osrf_prefork.c +++ b/src/libopensrf/osrf_prefork.c @@ -69,14 +69,14 @@ int osrf_prefork_run(char* appname) { prefork_simple* forker = prefork_simple_init( osrfSystemGetTransportClient(), maxr, minc, maxc); - forker->appname = strdup(appname); - forker->keepalive = kalive; - if(forker == NULL) { osrfLogError( OSRF_LOG_MARK, "osrf_prefork_run() failed to create prefork_simple object"); return -1; } + forker->appname = strdup(appname); + forker->keepalive = kalive; + prefork_launch_children(forker); osrf_prefork_register_routers(appname);