Skip to content

Conversation

@laanwj
Copy link
Member

@laanwj laanwj commented Mar 3, 2016

It looks like, TorController::disconnected_cb(TorControlConnection& conn) gets called multiple times which results in multiple event_new().

Avoid this by creating the event only once in the constructore, and deleting it only once in the destructor (thanks to Cory Fields for the idea).

Replaces the fix by Jonas Schnelli in #7610, see discussion there.

It looks like, TorController::disconnected_cb(TorControlConnection&
conn) gets called multiple times which results in multiple event_new().

Avoid this by creating the event only once in the constructore, and
deleting it only once in the destructor (thanks to Cory Fields for the
idea).

Replaces the fix by Jonas Schnelli in bitcoin#7610, see discussion there.
@jonasschnelli
Copy link
Contributor

utACK.

@theuni
Copy link
Member

theuni commented Mar 4, 2016

ut ACK

@laanwj laanwj merged commit e219503 into bitcoin:master Mar 11, 2016
laanwj added a commit that referenced this pull request Mar 11, 2016
e219503 Fix memleak in TorController [rework] (Wladimir J. van der Laan)
maflcko pushed a commit to maflcko/bitcoin-core that referenced this pull request Apr 27, 2016
It looks like, TorController::disconnected_cb(TorControlConnection&
conn) gets called multiple times which results in multiple event_new().

Avoid this by creating the event only once in the constructore, and
deleting it only once in the destructor (thanks to Cory Fields for the
idea).

Replaces the fix by Jonas Schnelli in bitcoin#7610, see discussion there.

Github-Pull: bitcoin#7637
Rebased-From: e219503
@maflcko
Copy link
Member

maflcko commented Jun 9, 2016

Backported as part of #7938. Removing label 'Needs backport'.

thokon00 pushed a commit to faircoin/faircoin that referenced this pull request Jun 28, 2016
It looks like, TorController::disconnected_cb(TorControlConnection&
conn) gets called multiple times which results in multiple event_new().

Avoid this by creating the event only once in the constructore, and
deleting it only once in the destructor (thanks to Cory Fields for the
idea).

Replaces the fix by Jonas Schnelli in bitcoin#7610, see discussion there.

Github-Pull: bitcoin#7637
Rebased-From: e219503
@bitcoin bitcoin locked as resolved and limited conversation to collaborators Sep 8, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants