• Home
  • History
  • Annotate
  • Raw
  • Download
  • only in /netgear-R7000-V1.0.7.12_1.2.5/ap/gpl/iserver/libevent-1.4.14b-stable/WIN32-Code/

Lines Matching refs:win32op

97 struct win32op {
131 realloc_fd_sets(struct win32op *op, size_t new_size)
161 get_event_entry(struct win32op *op, SOCKET s, int create)
179 do_fd_set(struct win32op *op, struct event_entry *ent, int read)
205 do_fd_clear(struct win32op *op, struct event_entry *ent, int read)
237 struct win32op *winop;
239 if (!(winop = calloc(1, sizeof(struct win32op))))
275 struct win32op *win32op = op;
279 if (win32op->signals_are_broken)
285 ent = get_event_entry(win32op, ev->ev_fd, 1);
291 if (do_fd_set(win32op, ent, 1)<0)
296 if (do_fd_set(win32op, ent, 0)<0)
306 struct win32op *win32op = op;
312 if (!(ent = get_event_entry(win32op, ev->ev_fd, 0)))
316 do_fd_clear(win32op, ent, 1);
320 do_fd_clear(win32op, ent, 0);
324 RB_REMOVE(event_map, &win32op->event_root, ent);
353 struct win32op *win32op = op;
360 fd_set_copy(win32op->readset_out, win32op->readset_in);
361 fd_set_copy(win32op->exset_out, win32op->readset_in);
362 fd_set_copy(win32op->writeset_out, win32op->writeset_in);
365 (win32op->readset_out->fd_count > win32op->writeset_out->fd_count) ?
366 win32op->readset_out->fd_count : win32op->writeset_out->fd_count;
376 (struct fd_set*)win32op->readset_out,
377 (struct fd_set*)win32op->writeset_out,
378 (struct fd_set*)win32op->exset_out, tv);
389 if (win32op->readset_out->fd_count) {
390 i = rand() % win32op->readset_out->fd_count;
391 for (j=0; j<win32op->readset_out->fd_count; ++j) {
392 if (++i >= win32op->readset_out->fd_count)
394 s = win32op->readset_out->fd_array[i];
395 if ((ent = get_event_entry(win32op, s, 0)) && ent->read_event)
399 if (win32op->exset_out->fd_count) {
400 i = rand() % win32op->exset_out->fd_count;
401 for (j=0; j<win32op->exset_out->fd_count; ++j) {
402 if (++i >= win32op->exset_out->fd_count)
404 s = win32op->exset_out->fd_array[i];
405 if ((ent = get_event_entry(win32op, s, 0)) && ent->read_event)
409 if (win32op->writeset_out->fd_count) {
410 i = rand() % win32op->writeset_out->fd_count;
411 for (j=0; j<win32op->writeset_out->fd_count; ++j) {
412 if (++i >= win32op->exset_out->fd_count)
414 s = win32op->writeset_out->fd_array[i];
415 if ((ent = get_event_entry(win32op, s, 0)) && ent->write_event)
427 struct win32op *win32op = arg;
430 if (win32op->readset_in)
431 free(win32op->readset_in);
432 if (win32op->writeset_in)
433 free(win32op->writeset_in);
434 if (win32op->readset_out)
435 free(win32op->readset_out);
436 if (win32op->writeset_out)
437 free(win32op->writeset_out);
438 if (win32op->exset_out)
439 free(win32op->exset_out);
442 memset(win32op, 0, sizeof(win32op));
443 free(win32op);