OpenBSD CVS

CVS log for src/lib/libevent/event.c


[BACK] Up to [local] / src / lib / libevent

Request diff between arbitrary revisions


Default branch: MAIN


Revision 1.42 / (download) - annotate - [select for diffs], Tue Dec 27 23:05:55 2022 UTC (17 months, 2 weeks ago) by jmc
Branch: MAIN
CVS Tags: OPENBSD_7_5_BASE, OPENBSD_7_5, OPENBSD_7_4_BASE, OPENBSD_7_4, OPENBSD_7_3_BASE, OPENBSD_7_3, HEAD
Changes since 1.41: +4 -4 lines
Diff to previous 1.41 (colored)

spelling fixes; from paul tagliamonte
ok nicm

Revision 1.41 / (download) - annotate - [select for diffs], Wed May 1 19:14:25 2019 UTC (5 years, 1 month ago) by jca
Branch: MAIN
CVS Tags: OPENBSD_7_2_BASE, OPENBSD_7_2, OPENBSD_7_1_BASE, OPENBSD_7_1, OPENBSD_7_0_BASE, OPENBSD_7_0, OPENBSD_6_9_BASE, OPENBSD_6_9, OPENBSD_6_8_BASE, OPENBSD_6_8, OPENBSD_6_7_BASE, OPENBSD_6_7, OPENBSD_6_6_BASE, OPENBSD_6_6
Changes since 1.40: +5 -9 lines
Diff to previous 1.40 (colored)

Tweaks previous: gettime() can be void, use TIMESPEC_TO_TIMEVAL

ok nicm@ tobias@ cheloha@

Revision 1.40 / (download) - annotate - [select for diffs], Wed May 1 19:12:47 2019 UTC (5 years, 1 month ago) by jca
Branch: MAIN
Changes since 1.39: +8 -66 lines
Diff to previous 1.39 (colored)

Require clock_gettime(CLOCK_MONOTONIC) and remove fallback code

If clock_gettime(CLOCK_MONOTONIC) fails here, something is really wrong.
Lots of userland already require it anyway.  Removing the fallback code
means less code, less global state and less fiddling with the timeheap
internals.

ok nicm@ tedu@ tobias@ cheloha@

Revision 1.39 / (download) - annotate - [select for diffs], Mon Apr 29 17:11:51 2019 UTC (5 years, 1 month ago) by tobias
Branch: MAIN
Changes since 1.38: +5 -4 lines
Diff to previous 1.38 (colored)

Switched min_heap to size_t to prevent integer overflows.

Also, as deraadt suggested, switched realloc to recallocarray to at least
prevent uninitialized memory to be used as pointers in case of other
programming errors. A proper solution (not using an array) needs more work.

This change occured in sync with upstream libevent 2.2.

with input by and ok bluhm, jca, tedu

Revision 1.38 / (download) - annotate - [select for diffs], Tue Jan 6 23:11:23 2015 UTC (9 years, 5 months ago) by bluhm
Branch: MAIN
CVS Tags: OPENBSD_6_5_BASE, OPENBSD_6_5, OPENBSD_6_4_BASE, OPENBSD_6_4, OPENBSD_6_3_BASE, OPENBSD_6_3, OPENBSD_6_2_BASE, OPENBSD_6_2, OPENBSD_6_1_BASE, OPENBSD_6_1, OPENBSD_6_0_BASE, OPENBSD_6_0, OPENBSD_5_9_BASE, OPENBSD_5_9, OPENBSD_5_8_BASE, OPENBSD_5_8, OPENBSD_5_7_BASE, OPENBSD_5_7
Changes since 1.37: +2 -5 lines
Diff to previous 1.37 (colored)

Backout revision 1.37.  Setting ev->ev_pncalls to NULL results in
a use after free if the callback has freed the ev.  With F in
malloc.conf both tmux and the regression tests triggered a segmentation
fault.
OK nicm@

Revision 1.37 / (download) - annotate - [select for diffs], Tue Jan 6 11:27:35 2015 UTC (9 years, 5 months ago) by bluhm
Branch: MAIN
Changes since 1.36: +5 -2 lines
Diff to previous 1.36 (colored)

Apply commit 2d8cf0b720cdd5f9f292f174a10ff74e62a380ec from upstream.
- Defensive programming to prevent (hopefully impossible) stack-stomping
OK nicm@

Revision 1.36 / (download) - annotate - [select for diffs], Thu Oct 30 16:45:37 2014 UTC (9 years, 7 months ago) by bluhm
Branch: MAIN
Changes since 1.35: +11 -11 lines
Diff to previous 1.35 (colored)

Fix whitespace errors in libevent.
OK nicm@

Revision 1.35 / (download) - annotate - [select for diffs], Wed Oct 29 22:47:29 2014 UTC (9 years, 7 months ago) by bluhm
Branch: MAIN
Changes since 1.34: +16 -17 lines
Diff to previous 1.34 (colored)

After removing all the #ifdef, the wrappers in evutil are rather
useless.  Let libevent call the libc functions directly.
OK nicm@

Revision 1.34 / (download) - annotate - [select for diffs], Fri Oct 17 22:59:46 2014 UTC (9 years, 7 months ago) by bluhm
Branch: MAIN
Changes since 1.33: +1 -31 lines
Diff to previous 1.33 (colored)

Remove #ifdef HAVE_backend and remove references to unimplemented
backends.
OK nicm@

Revision 1.33 / (download) - annotate - [select for diffs], Fri Oct 17 20:52:59 2014 UTC (9 years, 7 months ago) by bluhm
Branch: MAIN
Changes since 1.32: +1 -5 lines
Diff to previous 1.32 (colored)

Remove some #ifdef HAVE_syscall.
OK nicm@

Revision 1.32 / (download) - annotate - [select for diffs], Fri Oct 17 19:16:01 2014 UTC (9 years, 7 months ago) by bluhm
Branch: MAIN
Changes since 1.31: +2 -5 lines
Diff to previous 1.31 (colored)

Remove #ifdef HAVE_.*_H, just include the header files.
Do not include sys/param.h.
OK nicm@

Revision 1.31 / (download) - annotate - [select for diffs], Thu Oct 16 07:38:06 2014 UTC (9 years, 7 months ago) by bluhm
Branch: MAIN
Changes since 1.30: +1 -4 lines
Diff to previous 1.30 (colored)

Remove #ifdef HAVE_CONFIG_H, there is no config.h file.
OK nicm@

Revision 1.30 / (download) - annotate - [select for diffs], Wed Oct 8 20:14:19 2014 UTC (9 years, 8 months ago) by bluhm
Branch: MAIN
Changes since 1.29: +1 -14 lines
Diff to previous 1.29 (colored)

iRemove the #ifdef WIN32 implementation from libevent.
OK nicm@

Revision 1.29 / (download) - annotate - [select for diffs], Mon Sep 1 13:26:29 2014 UTC (9 years, 9 months ago) by bluhm
Branch: MAIN
Changes since 1.28: +2 -3 lines
Diff to previous 1.28 (colored)

The libevent event_log() function called by event_msgx() adds a new
line itself.  Do not print a double new line when EVENT_SHOW_METHOD
is set.
OK nicm@

Revision 1.28 / (download) - annotate - [select for diffs], Thu Apr 3 11:27:02 2014 UTC (10 years, 2 months ago) by eric
Branch: MAIN
CVS Tags: OPENBSD_5_6_BASE, OPENBSD_5_6
Changes since 1.27: +66 -1 lines
Diff to previous 1.27 (colored)

add helper functions to use asr with libevent.

ok deraadt@

Revision 1.27 / (download) - annotate - [select for diffs], Wed Apr 17 15:31:49 2013 UTC (11 years, 1 month ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_5_5_BASE, OPENBSD_5_5, OPENBSD_5_4_BASE, OPENBSD_5_4
Changes since 1.26: +4 -4 lines
Diff to previous 1.26 (colored)

(long long) and %lld for big time_t
ok nicm, who will pass it upstream

Revision 1.26 / (download) - annotate - [select for diffs], Tue Aug 28 09:09:56 2012 UTC (11 years, 9 months ago) by pascal
Branch: MAIN
CVS Tags: OPENBSD_5_3_BASE, OPENBSD_5_3
Changes since 1.25: +2 -2 lines
Diff to previous 1.25 (colored)

Expose _EVENT_VERSION in event.h.  This is expected by net/tor, which will spew
out scary warnings if it's not there.  Bump minor accordingly.

Requested by and ok dcoppa@, ok nicm@

Revision 1.25 / (download) - annotate - [select for diffs], Mon Aug 30 07:54:29 2010 UTC (13 years, 9 months ago) by nicm
Branch: MAIN
CVS Tags: OPENBSD_5_2_BASE, OPENBSD_5_2, OPENBSD_5_1_BASE, OPENBSD_5_1, OPENBSD_5_0_BASE, OPENBSD_5_0, OPENBSD_4_9_BASE, OPENBSD_4_9
Changes since 1.24: +7 -2 lines
Diff to previous 1.24 (colored)

Fix from upstream to make all backends reinit on event_reinit(). This
was not being done for poll and select, so after fork they would remain
using the same socketpair for signal notification, leading to a race
between the two processes to read from it and hangs.

Problem originally reported by kili@.

ok gilles

Revision 1.24 / (download) - annotate - [select for diffs], Mon Jul 12 18:03:38 2010 UTC (13 years, 11 months ago) by nicm
Branch: MAIN
CVS Tags: OPENBSD_4_8_BASE, OPENBSD_4_8
Changes since 1.23: +26 -4 lines
Diff to previous 1.23 (colored)

Update to 1.4.14b.

From their change log:
 o Fix memory-leak of signal handler array with kqueue. [backport]
 o Make evutil_make_socket_nonblocking() leave any other flags alone.
 o Adjusted fcntl() retval comparison on evutil_make_socket_nonblocking().
 o Re-add event_siglcb; some old code _was_ still using it. :(
 o Fix a free(NULL) in min_heap.h
 o Clean up properly when adding a signal handler fails.

Also a local change to use an int rather than a long for fcntl().

ok guenther deraadt

Revision 1.23 / (download) - annotate - [select for diffs], Wed Apr 21 21:02:46 2010 UTC (14 years, 1 month ago) by nicm
Branch: MAIN
Changes since 1.22: +2 -2 lines
Diff to previous 1.22 (colored)

Clean up the awful _EVENT_* poo in the libevent headers, and don't
install event-config.h.

Pointed out by deraadt.

Revision 1.22 / (download) - annotate - [select for diffs], Wed Apr 21 20:02:40 2010 UTC (14 years, 1 month ago) by nicm
Branch: MAIN
Changes since 1.21: +244 -165 lines
Diff to previous 1.21 (colored)

Update libevent to 1.4.13.

This is the core library only, the DNS parts are removed and it does not
include the other extra bits (HTTP, DNS, and RPC), a separate port for
these will appear in due course.

Thanks to jsg, sthen, alek, gilles, jacekm, bernd and any others I've
forgotten for testing/comments.

Note that /usr/include/evdns.h should be removed after updating.

ok deraadt

Revision 1.21 / (download) - annotate - [select for diffs], Thu Nov 12 05:44:29 2009 UTC (14 years, 7 months ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_4_7_BASE, OPENBSD_4_7
Changes since 1.20: +3 -3 lines
Diff to previous 1.20 (colored)

change back to preferring kqueue, now that nicm, tedu and i have
fixed it (or, all the issues we are aware of so far).
discussed with nicm

Revision 1.20 / (download) - annotate - [select for diffs], Fri Oct 30 13:51:29 2009 UTC (14 years, 7 months ago) by deraadt
Branch: MAIN
Changes since 1.19: +4 -4 lines
Diff to previous 1.19 (colored)

stop using kqueue.

Revision 1.19 / (download) - annotate - [select for diffs], Fri May 2 18:26:42 2008 UTC (16 years, 1 month ago) by brad
Branch: MAIN
CVS Tags: OPENBSD_4_6_BASE, OPENBSD_4_6, OPENBSD_4_5_BASE, OPENBSD_4_5, OPENBSD_4_4_BASE, OPENBSD_4_4
Changes since 1.18: +2 -2 lines
Diff to previous 1.18 (colored)

- Use a const pointer for bufferevent_write.
- Make event_init return struct event_base *.

From the libevent SVN repo.

ok millert@

Revision 1.18 / (download) - annotate - [select for diffs], Fri May 2 06:09:11 2008 UTC (16 years, 1 month ago) by brad
Branch: MAIN
Changes since 1.17: +111 -62 lines
Diff to previous 1.17 (colored)

Update to libevent 1.3e while retaining our local changes.

"No objection" millert@
"the diff looks and works fine" reyk@

Revision 1.17 / (download) - annotate - [select for diffs], Mon Mar 19 15:12:49 2007 UTC (17 years, 2 months ago) by millert
Branch: MAIN
CVS Tags: OPENBSD_4_3_BASE, OPENBSD_4_3, OPENBSD_4_2_BASE, OPENBSD_4_2
Changes since 1.16: +20 -8 lines
Diff to previous 1.16 (colored)

Update to libevent-1.3b while retaining our local changes.  beck@ OK

Revision 1.16 / (download) - annotate - [select for diffs], Tue Feb 13 20:10:57 2007 UTC (17 years, 4 months ago) by millert
Branch: MAIN
CVS Tags: OPENBSD_4_1_BASE, OPENBSD_4_1
Changes since 1.15: +5 -8 lines
Diff to previous 1.15 (colored)

Avoid double recacl when loop_once is used.
From libevent SVN via brad@.

Revision 1.15 / (download) - annotate - [select for diffs], Sun Feb 4 18:59:12 2007 UTC (17 years, 4 months ago) by millert
Branch: MAIN
Changes since 1.14: +3 -1 lines
Diff to previous 1.14 (colored)

Two libevent fixes from the SVN repo:
allow gotsig to terminate active event loop and evbuffer_find fix.
OK brad@ pyr@

Revision 1.14 / (download) - annotate - [select for diffs], Sun Nov 5 03:39:40 2006 UTC (17 years, 7 months ago) by brad
Branch: MAIN
Changes since 1.13: +7 -2 lines
Diff to previous 1.13 (colored)

fix a potential memory leak in event_once().

From Niels Provos via the libevent SVN repo, by Scott Lamb

tested by niallo@

ok deraadt@

Revision 1.13 / (download) - annotate - [select for diffs], Thu Mar 30 06:32:36 2006 UTC (18 years, 2 months ago) by brad
Branch: MAIN
CVS Tags: OPENBSD_4_0_BASE, OPENBSD_4_0
Changes since 1.12: +29 -1 lines
Diff to previous 1.12 (colored)

introduce a way to free the base.

From libevent CVS

Revision 1.12 / (download) - annotate - [select for diffs], Tue Mar 28 15:32:13 2006 UTC (18 years, 2 months ago) by brad
Branch: MAIN
Changes since 1.11: +30 -8 lines
Diff to previous 1.11 (colored)

use clock_gettime if available.

From claudio@ via libevent CVS

ok claudio@

Revision 1.11 / (download) - annotate - [select for diffs], Sat Jul 2 07:15:13 2005 UTC (18 years, 11 months ago) by grunk
Branch: MAIN
CVS Tags: OPENBSD_3_9_BASE, OPENBSD_3_9, OPENBSD_3_8_BASE, OPENBSD_3_8
Changes since 1.10: +4 -4 lines
Diff to previous 1.10 (colored)

zap trailing whitespaces, no binary change

ok brad@ beck@

Revision 1.10 / (download) - annotate - [select for diffs], Wed May 4 03:17:48 2005 UTC (19 years, 1 month ago) by brad
Branch: MAIN
Changes since 1.9: +3 -2 lines
Diff to previous 1.9 (colored)

update to libevent 1.0d; keep local changes

thanks to Alexander von Gernler for testing
and some bug fixes

ok mpf@ norby@

Revision 1.9 / (download) - annotate - [select for diffs], Fri Apr 22 00:56:25 2005 UTC (19 years, 1 month ago) by brad
Branch: MAIN
Changes since 1.8: +296 -116 lines
Diff to previous 1.8 (colored)

update to libevent 1.0c; keep local changes

no shared lib so no ABI/API check is necessary

thanks to Alexander von Gernler for submitting
another diff in an attempt to update libevent
and for a use-after-free fix.

ok henning@ deraadt@

Revision 1.8 / (download) - annotate - [select for diffs], Tue Apr 19 08:07:45 2005 UTC (19 years, 1 month ago) by deraadt
Branch: MAIN
Changes since 1.7: +115 -295 lines
Diff to previous 1.7 (colored)

backout.  not discussed, and very wrong.  bad brad

Revision 1.7 / (download) - annotate - [select for diffs], Tue Apr 19 02:03:12 2005 UTC (19 years, 1 month ago) by brad
Branch: MAIN
Changes since 1.6: +296 -116 lines
Diff to previous 1.6 (colored)

update to libevent 1.0c; keep local changes

Revision 1.6 / (download) - annotate - [select for diffs], Wed Apr 13 16:15:09 2005 UTC (19 years, 2 months ago) by reyk
Branch: MAIN
Changes since 1.5: +5 -4 lines
Diff to previous 1.5 (colored)

use "volatile sig_atomic_t" types instead of "int" for signal flags.

ok deraadt@ henning@ provos

Revision 1.5 / (download) - annotate - [select for diffs], Wed Apr 28 06:53:12 2004 UTC (20 years, 1 month ago) by brad
Branch: MAIN
CVS Tags: OPENBSD_3_7_BASE, OPENBSD_3_7, OPENBSD_3_6_BASE, OPENBSD_3_6
Changes since 1.4: +136 -42 lines
Diff to previous 1.4 (colored)

update to libevent 0.8; keep local changes

ok markus@

Revision 1.4 / (download) - annotate - [select for diffs], Wed Jul 9 10:54:38 2003 UTC (20 years, 11 months ago) by markus
Branch: MAIN
CVS Tags: OPENBSD_3_5_BASE, OPENBSD_3_5, OPENBSD_3_4_BASE, OPENBSD_3_4
Changes since 1.3: +47 -7 lines
Diff to previous 1.3 (colored)

update to libevent-0.7a.tar.gz; keep local changes

Revision 1.3 / (download) - annotate - [select for diffs], Thu Jun 19 18:52:12 2003 UTC (20 years, 11 months ago) by mickey
Branch: MAIN
Changes since 1.2: +5 -5 lines
Diff to previous 1.2 (colored)

constify constant structures; niels ok

Revision 1.2 / (download) - annotate - [select for diffs], Tue Jun 25 15:50:15 2002 UTC (21 years, 11 months ago) by mickey
Branch: MAIN
CVS Tags: OPENBSD_3_3_BASE, OPENBSD_3_3, OPENBSD_3_2_BASE, OPENBSD_3_2
Changes since 1.1: +2 -0 lines
Diff to previous 1.1 (colored)

rcsids

Revision 1.1.1.1 / (download) - annotate - [select for diffs] (vendor branch), Sat Jun 15 18:01:37 2002 UTC (22 years ago) by provos
Branch: PROVOS00
CVS Tags: EVENT00
Changes since 1.1: +0 -0 lines
Diff to previous 1.1 (colored)

import libevent an event notification abstraction on top of select or kqueue
supporting timeout and signal callsbacks, too.  okay deraadt@ millert@

Revision 1.1 / (download) - annotate - [select for diffs], Sat Jun 15 18:01:37 2002 UTC (22 years ago) by provos
Branch: MAIN

Initial revision

This form allows you to request diff's between any two revisions of a file. You may select a symbolic revision name using the selection box or you may type in a numeric name using the type-in text box.