/[monit]/monit/util.c
ViewVC logotype

Diff of /monit/util.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.171 by hauk, Sat Nov 19 18:18:21 2005 UTC revision 1.172 by hauk, Sat Nov 19 18:25:16 2005 UTC
# Line 1143  int Util_isProcessRunning(Service_T s) { Line 1143  int Util_isProcessRunning(Service_T s) {
1143        
1144    errno= 0;    errno= 0;
1145    if((pid= Util_getPid(s->path)) >= 0) {    if((pid= Util_getPid(s->path)) >= 0) {
1146      DEBUG("Info: Got pid %d from %s\n", pid, s->path);      DEBUG("Info: Got pid [%d] from '%s'\n", pid, s->path);
1147      if( (getpgid(pid) > -1) || (errno == EPERM) )      if( (getpgid(pid) > -1) || (errno == EPERM) )
1148        return pid;        return pid;
1149      DEBUG("Info: Error testing process id [%d] -- %s\n", pid, STRERROR);      DEBUG("Info: Error testing process id [%d] -- %s\n", pid, STRERROR);
         } else {  
                 DEBUG("Info: No pid found at %s\n", s->path);  
1150          }          }
1151    Util_resetInfo(s);    Util_resetInfo(s);
1152        

Legend:
Removed from v.1.171  
changed lines
  Added in v.1.172

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26