[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

Re: [tor-bugs] #5557 [Tor Bridge]: Tor helpers' launch error message contains useless whitespace



#5557: Tor helpers' launch error message contains useless whitespace
------------------------+---------------------------------------------------
 Reporter:  asn         |          Owner:                    
     Type:  defect      |         Status:  new               
 Priority:  normal      |      Milestone:  Tor: 0.2.3.x-final
Component:  Tor Bridge  |        Version:                    
 Keywords:              |         Parent:                    
   Points:              |   Actualpoints:                    
------------------------+---------------------------------------------------

Comment(by asn):

 Replying to [comment:5 sjmurdoch]:
 > I agree on the aesthetics point, but does this actually cause a bug in
 log_from_pipe? SPAWN_ERROR_MESSAGE has a trailing space, and the MacOS X
 manpage says "The format string may also contain other characters.  White
 space (such as blanks, tabs, or newlines) in the format string match any
 amount of white space, including none, in the input." Can we not assume
 this on all platforms?

 `tor_sscanf()` doesn't support the whitespace trick. In `tor_vsscanf()` we
 have:
 {{{
     if (*pattern != '%') {
       if (*buf == *pattern) {
         ++buf;
         ++pattern;
         continue;
       } else {
         return n_matched;
       }
 }}}

 Not sure if this is a design choice or a bug.

-- 
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/5557#comment:6>
Tor Bug Tracker & Wiki <https://trac.torproject.org/>
The Tor Project: anonymity online
_______________________________________________
tor-bugs mailing list
tor-bugs@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-bugs