[tor-bugs] #2190 [Tor Client]: Possible reentrant calls to libevent from libevent logging callback
Tor Bug Tracker & Wiki
torproject-admin at torproject.org
Sat Dec 11 10:06:02 UTC 2010
#2190: Possible reentrant calls to libevent from libevent logging callback
------------------------+---------------------------------------------------
Reporter: nickm | Owner: rransom
Type: defect | Status: needs_review
Priority: normal | Milestone: Tor: 0.2.2.x-final
Component: Tor Client | Version:
Keywords: | Parent:
------------------------+---------------------------------------------------
Comment(by cypherpunks):
Branch "bug2190_the_hard_way" possible incomplete:
{{{
messages = pending_cb_messages;
pending_cb_messages = smartlist_create();
do {
}}}
...
{{{
smartlist_clear(messages);
messages_tmp = pending_cb_messages;
pending_cb_messages = messages;
messages = messages_tmp;
} while (smartlist_len(messages));
}}}
Because if no one can change pending_cb_messages during do{}while() the
the last part is equal at least to:
{{{
smartlist_clear(messages);
} while (0);
}}}
--
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/2190#comment:6>
Tor Bug Tracker & Wiki <https://trac.torproject.org/>
The Tor Project: anonymity online
More information about the tor-bugs
mailing list