summaryrefslogtreecommitdiff
path: root/monitor_oncore.c
diff options
context:
space:
mode:
authorGary E. Miller <gem@rellim.com>2015-03-09 15:52:37 -0700
committerGary E. Miller <gem@rellim.com>2015-03-09 15:52:37 -0700
commitc0cb4456b86779f67a59819dbd797caea6cb0b99 (patch)
treecbef94125416bfe5d6a2b7ebd4d05cef86bc42ca /monitor_oncore.c
parenta2f003b7075dd6a262e1a89ff6fac327c3bef097 (diff)
downloadgpsd-c0cb4456b86779f67a59819dbd797caea6cb0b99.tar.gz
Fix cppcheck complaints about not enough parenthesis.
Change this: A & B ? 0 : 1 To this: (A & B) ? 0 : 1 No logic or functional change.
Diffstat (limited to 'monitor_oncore.c')
-rw-r--r--monitor_oncore.c20
1 files changed, 10 insertions, 10 deletions
diff --git a/monitor_oncore.c b/monitor_oncore.c
index c763b399..6e08c34b 100644
--- a/monitor_oncore.c
+++ b/monitor_oncore.c
@@ -229,15 +229,15 @@ static void oncore_update(void)
/*@ -predboolothers @*/
(void)snprintf(statusbuf, sizeof(statusbuf), "%s%s%s%s%s%s%s%s%s",
- status & 0x80 ? "PProp " : "",
- status & 0x40 ? "PoorGeom " : "",
- status & 0x20 ? "3D " : "",
- status & 0x10 ? "2D " : "",
- status & 0x08 ? "Acq/PHold " : "",
- status & 0x04 ? "Diff " : "",
- status & 0x02 ? "Ins (<3 SV) " : "",
- status & 0x01 ? "BadAlm " : "",
- dopt & 0x20 ? "survey " : "");
+ (status & 0x80) ? "PProp " : "",
+ (status & 0x40) ? "PoorGeom " : "",
+ (status & 0x20) ? "3D " : "",
+ (status & 0x10) ? "2D " : "",
+ (status & 0x08) ? "Acq/PHold " : "",
+ (status & 0x04) ? "Diff " : "",
+ (status & 0x02) ? "Ins (<3 SV) " : "",
+ (status & 0x01) ? "BadAlm " : "",
+ (dopt & 0x20) ? "survey " : "");
/*@ +predboolothers @*/
(void)mvwprintw(Ea1win, 3, 24, "%-37s", statusbuf);
@@ -246,7 +246,7 @@ static void oncore_update(void)
/*@ -predboolothers @*/
(void)mvwprintw(Ea1win, 2, 27, "%s %4.1f",
- dopt & 1 ? "hdop" : "pdop", dop);
+ (dopt & 1) ? "hdop" : "pdop", dop);
/*@ +predboolothers @*/
(void)mvwprintw(Ea1win, 3, 10, "%d/%d ", nsat, nvis);