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

Diff of /monit/monit_http.c

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

revision 1.17 by martinp, Sun Sep 14 10:34:47 2003 UTC revision 1.18 by martinp, Sun Sep 14 11:27:05 2003 UTC
# Line 126  void monit_http(int action) { Line 126  void monit_http(int action) {
126    switch(action) {    switch(action) {
127            
128    case STOP_HTTP:    case STOP_HTTP:
129      log("Stopping %s HTTP server\n", prog);      log("%s HTTP server stopping\n", prog);
130      stop_httpd();      stop_httpd();
131        if( (status= pthread_join(thread, NULL)) != 0) {
132          log("%s: Failed to stop the http server. Thread error -- %s.\n",
133              prog, strerror(status));
134        } else {
135          log("%s HTTP server stopped\n", prog);
136        }
137      break;      break;
138    
139    case START_HTTP:    case START_HTTP:
# Line 155  static void *thread_wrapper(void *arg) { Line 161  static void *thread_wrapper(void *arg) {
161    
162    sigset_t ns;    sigset_t ns;
163    
   pthread_detach(pthread_self());  
164    /* Block collective signals in the http thread. The http server is    /* Block collective signals in the http thread. The http server is
165     * taken down gracefully by signaling the main monit thread */     * taken down gracefully by signaling the main monit thread */
166    set_signal_block(&ns, NULL);    set_signal_block(&ns, NULL);

Legend:
Removed from v.1.17  
changed lines
  Added in v.1.18

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