[tor-bugs] #10053 [- Select a component]: vidalia-0.2.20: 2 * bad if test ?

Tor Bug Tracker & Wiki blackhole at torproject.org
Wed Oct 30 12:59:11 UTC 2013


#10053: vidalia-0.2.20: 2 * bad if test ?
----------------------------------+---------------------
 Reporter:  dcb                   |          Owner:
     Type:  defect                |         Status:  new
 Priority:  normal                |      Milestone:
Component:  - Select a component  |        Version:
 Keywords:                        |  Actual Points:
Parent ID:                        |         Points:
----------------------------------+---------------------
 I just compiled vidalia-0.2.20 with extra gcc compiler flag -Wlogical-op

 It said

 1.

 vidalia-0.2.20/src/torcontrol/Circuit.cpp:82:17: warning: logical 'and' of
 mutually exclusive tests is always false [-Wlogical-op]

 Source code is

     if (c < '0' && c > '9' && c < 'A' && c > 'Z' && c < 'a' && c > 'z')

 Suggest swap && for ||

 2.

 vidalia-0.2.20/src/torcontrol/Stream.cpp:92:17: warning: logical 'and' of
 mutually exclusive tests is always false [-Wlogical-op]

 Duplicate.

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


More information about the tor-bugs mailing list