[tor-bugs] #16630 [Tor]: Remove casting when registering signals

Tor Bug Tracker & Wiki blackhole at torproject.org
Tue Jul 21 12:58:05 UTC 2015


#16630: Remove casting when registering signals
-------------------------+----------------------------------
 Reporter:  cypherpunks  |          Owner:
     Type:  enhancement  |         Status:  new
 Priority:  minor        |      Milestone:
Component:  Tor          |        Version:  Tor: unspecified
 Keywords:               |  Actual Points:
Parent ID:               |         Points:
-------------------------+----------------------------------
 The current code for registering signals, `handle_signals`, uses casting
 to convert the signal type into a pointer. The result is a pointer where
 its address is the signal type instead of an actual memory location.

 This hack requires the callback functions `signal_callback` and
 `process_signal` to do the same hack in reverse to get the signal type
 back.

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


More information about the tor-bugs mailing list