comparison src/core/ngx_cycle.c @ 6483:3a50ccd94333

Fixed ngx_os_signal_process() prototype.
author Ruslan Ermilov <ru@nginx.com>
date Thu, 31 Mar 2016 22:00:33 +0300
parents f01ab2dbcfdc
children 1bf4f21b1b72
comparison
equal deleted inserted replaced
6482:2b7dacb381ed 6483:3a50ccd94333
1004 1004
1005 ngx_int_t 1005 ngx_int_t
1006 ngx_signal_process(ngx_cycle_t *cycle, char *sig) 1006 ngx_signal_process(ngx_cycle_t *cycle, char *sig)
1007 { 1007 {
1008 ssize_t n; 1008 ssize_t n;
1009 ngx_int_t pid; 1009 ngx_pid_t pid;
1010 ngx_file_t file; 1010 ngx_file_t file;
1011 ngx_core_conf_t *ccf; 1011 ngx_core_conf_t *ccf;
1012 u_char buf[NGX_INT64_LEN + 2]; 1012 u_char buf[NGX_INT64_LEN + 2];
1013 1013
1014 ngx_log_error(NGX_LOG_NOTICE, cycle->log, 0, "signal process started"); 1014 ngx_log_error(NGX_LOG_NOTICE, cycle->log, 0, "signal process started");
1042 1042
1043 while (n-- && (buf[n] == CR || buf[n] == LF)) { /* void */ } 1043 while (n-- && (buf[n] == CR || buf[n] == LF)) { /* void */ }
1044 1044
1045 pid = ngx_atoi(buf, ++n); 1045 pid = ngx_atoi(buf, ++n);
1046 1046
1047 if (pid == NGX_ERROR) { 1047 if (pid == (ngx_pid_t) NGX_ERROR) {
1048 ngx_log_error(NGX_LOG_ERR, cycle->log, 0, 1048 ngx_log_error(NGX_LOG_ERR, cycle->log, 0,
1049 "invalid PID number \"%*s\" in \"%s\"", 1049 "invalid PID number \"%*s\" in \"%s\"",
1050 n, buf, file.name.data); 1050 n, buf, file.name.data);
1051 return 1; 1051 return 1;
1052 } 1052 }