Opened 8 years ago
Closed 8 years ago
#12894 closed bug (fixed)
[Patch] HaikuDepot: Fix -Wlogical-not-parentheses
Reported by: | mt | Owned by: | stippi |
---|---|---|---|
Priority: | normal | Milestone: | Unscheduled |
Component: | Applications/HaikuDepot | Version: | R1/Development |
Keywords: | Cc: | ||
Blocked By: | Blocking: | ||
Platform: | All |
Description
Modify if condition at line 154 [1], since negating return value of BEntry.GetPath() may not be B_OK.
/home/haiku/haiku/haiku/src/apps/haikudepot/ui/App.cpp:154:25: warning: logical not is only applied to the left hand side of this comparison [-Wlogical-not-parentheses] if (!entry.Exists() || !entry.GetPath(&path) == B_OK) { ^ ~~ /home/haiku/haiku/haiku/src/apps/haikudepot/ui/App.cpp:154:25: note: add parentheses after the '!' to evaluate the comparison first if (!entry.Exists() || !entry.GetPath(&path) == B_OK) { ^ ( ) /home/haiku/haiku/haiku/src/apps/haikudepot/ui/App.cpp:154:25: note: add parentheses around left hand side expression to silence this warning if (!entry.Exists() || !entry.GetPath(&path) == B_OK) { ^ ( )
Attachments (1)
Change History (3)
by , 8 years ago
Attachment: | 0025-HaikuDepot-Fix-Wlogical-not-parentheses.patch added |
---|
comment:1 by , 8 years ago
patch: | 0 → 1 |
---|
comment:2 by , 8 years ago
Resolution: | → fixed |
---|---|
Status: | new → closed |
Note:
See TracTickets
for help on using tickets.
Fixed in hrev50503.