mirror of
https://github.com/nginx/nginx.git
synced 2025-01-19 01:42:58 +08:00
fix building --test-build-rtsig and --test-build-eventport on FreeBSD 7
This commit is contained in:
parent
02d8e8e377
commit
6e8bc2b72d
@ -40,11 +40,6 @@ typedef struct port_notify {
|
||||
void *portnfy_user; /* user defined */
|
||||
} port_notify_t;
|
||||
|
||||
typedef struct itimerspec { /* definition per POSIX.4 */
|
||||
struct timespec it_interval;/* timer period */
|
||||
struct timespec it_value; /* timer expiration */
|
||||
} itimerspec_t;
|
||||
|
||||
int port_create(void)
|
||||
{
|
||||
return -1;
|
||||
@ -106,7 +101,7 @@ static char *ngx_eventport_init_conf(ngx_cycle_t *cycle, void *conf);
|
||||
static int ep = -1;
|
||||
static port_event_t *event_list;
|
||||
static ngx_uint_t nevents;
|
||||
static timer_t event_timer = -1;
|
||||
static timer_t event_timer = (timer_t) -1;
|
||||
|
||||
static ngx_str_t eventport_name = ngx_string("eventport");
|
||||
|
||||
@ -237,13 +232,13 @@ ngx_eventport_init(ngx_cycle_t *cycle, ngx_msec_t timer)
|
||||
static void
|
||||
ngx_eventport_done(ngx_cycle_t *cycle)
|
||||
{
|
||||
if (event_timer != -1) {
|
||||
if (event_timer != (timer_t) -1) {
|
||||
if (timer_delete(event_timer) == -1) {
|
||||
ngx_log_error(NGX_LOG_ALERT, cycle->log, ngx_errno,
|
||||
"timer_delete() failed");
|
||||
}
|
||||
|
||||
event_timer = -1;
|
||||
event_timer = (timer_t) -1;
|
||||
}
|
||||
|
||||
if (close(ep) == -1) {
|
||||
|
@ -12,8 +12,7 @@
|
||||
#if (NGX_TEST_BUILD_RTSIG)
|
||||
|
||||
#define F_SETSIG 10
|
||||
#define SIGRTMIN 33
|
||||
#define si_fd __spare__[0]
|
||||
#define si_fd _reason.__spare__.__spare2__[0]
|
||||
#define KERN_RTSIGNR 30
|
||||
#define KERN_RTSIGMAX 31
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user