dueling patches of pedantism
authormiker <miker@9efc2488-bf62-4759-914b-345cdb29e865>
Tue, 29 May 2007 13:08:53 +0000 (13:08 +0000)
committermiker <miker@9efc2488-bf62-4759-914b-345cdb29e865>
Tue, 29 May 2007 13:08:53 +0000 (13:08 +0000)
git-svn-id: svn://svn.open-ils.org/OpenSRF/trunk@925 9efc2488-bf62-4759-914b-345cdb29e865

src/libstack/osrf_system.c

index 2cda339..23c44ad 100644 (file)
@@ -105,11 +105,11 @@ int osrfSystemBootstrap( char* hostname, char* configfile, char* contextNode ) {
 
                                osrfLogInfo( OSRF_LOG_MARK, "Launching application %s with implementation %s", appname, libfile);
                
-                               int pid;
+                               pid_t pid;
                
                                if( (pid = fork()) ) { 
                                        // storage pid in local table for re-launching dead children...
-                                       osrfLogInfo( OSRF_LOG_MARK, "Launched application child %d", pid);
+                                       osrfLogInfo( OSRF_LOG_MARK, "Launched application child %ld", (long) pid);
        
                                } else {
                
@@ -135,10 +135,12 @@ int osrfSystemBootstrap( char* hostname, char* configfile, char* contextNode ) {
             if(errno == ECHILD)
                 osrfLogError(OSRF_LOG_MARK, "We have no more live services... exiting");
             else
-                osrfLogError(OSRF_LOG_MARK, "Exiting top-level system loop with error: %s", strerror(errno));
+               char* err_str = strerror(errno);
+                osrfLogError(OSRF_LOG_MARK, "Exiting top-level system loop with error: %s", err_str);
+               free(err_str);
             break;
         } else {
-            osrfLogError(OSRF_LOG_MARK, "We lost a top-level service process with PID %d", pid);
+            osrfLogError(OSRF_LOG_MARK, "We lost a top-level service process with PID %ld", pid);
         }
     }