[tor-bugs] #2046 [Tor Client]: Port Tor code for starting a background process to Windows

Tor Bug Tracker & Wiki torproject-admin at torproject.org
Tue Aug 30 14:11:11 UTC 2011

#2046: Port Tor code for starting a background process to Windows
 Reporter:  sjmurdoch   |          Owner:  sjmurdoch         
     Type:  task        |         Status:  needs_review      
 Priority:  major       |      Milestone:  Tor: 0.2.3.x-final
Component:  Tor Client  |        Version:                    
 Keywords:              |         Parent:  #1983             
   Points:              |   Actualpoints:                    
Changes (by sjmurdoch):

  * status:  accepted => needs_review


 OK, I believe I have addressed all of these issues, and the code is ready
 for review. FYI, the code you previously reviewed was 1da5081. Changes
 since then are:

 > '''Fix:'''
 > Split the C string processing stuff out of functions like
 log_from_handle, so
 > that we can do a unit test for it.  (If there's other string processing
 goop in
 > the spawn code, same logic applies).


 > Pass pointer to process_handle_t into tor_spawn_background, rather than
 > return a process_handle_t.


 > Have a separate, unit-tested function, that formats a command line
 properly for
 > windows.  It should handle filenames with a space (e.g.  C:\Program
 > also it should handle internal quotes. Look at Python's
 > and at http://msdn.microsoft.com/en-us/library/ms880421


 > For tor_get_exit_code: Let's return a define or an enum rather than a
 > tristate.


 > In tor_read_all_from_handle, I'd be more comfortable if it did an
 > tor_assert(byte_count + numread <= count);


 > '''Document and possibly fix:'''
 > In tor_log_from_handle: handle strings with embedded NULs; handle
 strings > 255 bytes (without splitting lines or outputting bogus
 newlines). See bug #2045.


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

More information about the tor-bugs mailing list