]> err.no Git - varnish/commit
I have grumbled about the evilness of "current_base" before, and this just
authorphk <phk@d4fa192b-c00b-0410-8231-f00ffab90ce4>
Mon, 3 Jul 2006 19:35:05 +0000 (19:35 +0000)
committerphk <phk@d4fa192b-c00b-0410-8231-f00ffab90ce4>
Mon, 3 Jul 2006 19:35:05 +0000 (19:35 +0000)
commitfa64465a68c77096be2e33d22223ab6e44385890
tree1645cab9ec18ae3d5e121c43ec24065907d567f9
parentef966747682f17c307e228903ea2a54594494ce7
I have grumbled about the evilness of "current_base" before, and this just
proves the point:  If two threads call event_init() at the same time,
they will both stomp on the same memory via current_base, and in all
likelyhood, neither of them will manage to get the job done properly.

Instead work on a local variable and don't assign to current_base
until the setup is complete.

This should be submitted to Niels Provos

git-svn-id: svn+ssh://projects.linpro.no/svn/varnish/trunk@288 d4fa192b-c00b-0410-8231-f00ffab90ce4
varnish-cache/contrib/libevent/event.c