• Home
  • History
  • Annotate
  • Raw
  • Download
  • only in /netgear-R7000-V1.0.7.12_1.2.5/ap/gpl/transmission/libevent-2.0.20-stable/

Lines Matching refs:win32op

68 struct win32op {
100 grow_fd_sets(struct win32op *op, unsigned new_num_fds)
119 do_fd_set(struct win32op *op, struct idx_info *ent, evutil_socket_t s, int read)
145 struct win32op *op, struct idx_info *ent, int read)
179 struct win32op *winop;
181 if (!(winop = mm_calloc(1, sizeof(struct win32op))))
217 struct win32op *win32op = base->evbase;
220 if ((events & EV_SIGNAL) && win32op->signals_are_broken)
228 if (do_fd_set(win32op, idx, fd, 1)<0)
232 if (do_fd_set(win32op, idx, fd, 0)<0)
242 struct win32op *win32op = base->evbase;
247 do_fd_clear(base, win32op, idx, 1);
249 do_fd_clear(base, win32op, idx, 0);
275 struct win32op *win32op = base->evbase;
281 if (win32op->resize_out_sets) {
282 size_t size = FD_SET_ALLOC_SIZE(win32op->num_fds_in_fd_sets);
283 if (!(win32op->readset_out = mm_realloc(win32op->readset_out, size)))
285 if (!(win32op->exset_out = mm_realloc(win32op->exset_out, size)))
287 if (!(win32op->writeset_out = mm_realloc(win32op->writeset_out, size)))
289 win32op->resize_out_sets = 0;
292 fd_set_copy(win32op->readset_out, win32op->readset_in);
293 fd_set_copy(win32op->exset_out, win32op->writeset_in);
294 fd_set_copy(win32op->writeset_out, win32op->writeset_in);
297 (win32op->readset_out->fd_count > win32op->writeset_out->fd_count) ?
298 win32op->readset_out->fd_count : win32op->writeset_out->fd_count;
313 (struct fd_set*)win32op->readset_out,
314 (struct fd_set*)win32op->writeset_out,
315 (struct fd_set*)win32op->exset_out, tv);
325 if (win32op->readset_out->fd_count) {
326 i = rand() % win32op->readset_out->fd_count;
327 for (j=0; j<win32op->readset_out->fd_count; ++j) {
328 if (++i >= win32op->readset_out->fd_count)
330 s = win32op->readset_out->fd_array[i];
334 if (win32op->exset_out->fd_count) {
335 i = rand() % win32op->exset_out->fd_count;
336 for (j=0; j<win32op->exset_out->fd_count; ++j) {
337 if (++i >= win32op->exset_out->fd_count)
339 s = win32op->exset_out->fd_array[i];
343 if (win32op->writeset_out->fd_count) {
345 i = rand() % win32op->writeset_out->fd_count;
346 for (j=0; j<win32op->writeset_out->fd_count; ++j) {
347 if (++i >= win32op->writeset_out->fd_count)
349 s = win32op->writeset_out->fd_array[i];
359 struct win32op *win32op = _base->evbase;
362 if (win32op->readset_in)
363 mm_free(win32op->readset_in);
364 if (win32op->writeset_in)
365 mm_free(win32op->writeset_in);
366 if (win32op->readset_out)
367 mm_free(win32op->readset_out);
368 if (win32op->writeset_out)
369 mm_free(win32op->writeset_out);
370 if (win32op->exset_out)
371 mm_free(win32op->exset_out);
374 memset(win32op, 0, sizeof(win32op));
375 mm_free(win32op);