[tor-bugs] #20716 [Core Tor/Tor]: memory leak in connection_handle_listener_read()

Tor Bug Tracker & Wiki blackhole at torproject.org
Thu Dec 1 15:16:56 UTC 2016


#20716: memory leak in connection_handle_listener_read()
--------------------------+------------------------------------
 Reporter:  arma          |          Owner:
     Type:  defect        |         Status:  needs_review
 Priority:  Medium        |      Milestone:  Tor: 0.2.9.x-final
Component:  Core Tor/Tor  |        Version:  Tor: 0.2.6.3-alpha
 Severity:  Normal        |     Resolution:
 Keywords:                |  Actual Points:
Parent ID:                |         Points:
 Reviewer:                |        Sponsor:
--------------------------+------------------------------------

Comment (by nickm):

 Your patch is trying to test for the opposite of `new_type == CONN_TYPE_AP
 && conn->socket_family == AF_UNIX` -- but that isn't `new_type !=
 CONN_TYPE_AP && conn->socket_family != AF_UNIX`.  It's `new_type !=
 CONN_TYPE_AP || conn->socket_family != AF_UNIX`.

 (Remember, `!(a && b) == !a || !b`.)

 How about what I have in bug20716_026 in my public repository?

 https://gitweb.torproject.org/nickm/tor.git/commit/?h=bug20716_026&id=3b6da3f90ccad60517f5b639d5340a7e6489be27

--
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/20716#comment:9>
Tor Bug Tracker & Wiki <https://trac.torproject.org/>
The Tor Project: anonymity online


More information about the tor-bugs mailing list