]> sigrok.org Git - libsigrok.git/commitdiff
gmc-mh-1x-2x: Fix compiler warning (clang).
authorUwe Hermann <redacted>
Tue, 31 Dec 2013 18:21:04 +0000 (19:21 +0100)
committerUwe Hermann <redacted>
Tue, 31 Dec 2013 18:21:04 +0000 (19:21 +0100)
  CC       libsigrok_hw_gmc_mh_1x_2x_la-protocol.lo
protocol.c:133:32: warning: equality comparison with extraneous
parentheses
      [-Wparentheses-equality]
                        } else if ((devc->scale1000 == 2)) {
                                    ~~~~~~~~~~~~~~~~^~~~
protocol.c:133:32: note: remove extraneous parentheses around the
comparison to
      silence this warning
                        } else if ((devc->scale1000 == 2)) {
                                   ~                ^   ~

hardware/gmc-mh-1x-2x/protocol.c

index 2b2b6966bc1eff168243730390cd5147d2901a5b..76b804cb499234695b84d85c1565234b9294df75 100644 (file)
@@ -130,7 +130,7 @@ static void decode_rs_16(uint8_t rs, struct dev_context *devc)
                                devc->mq = SR_MQ_TEMPERATURE;
                                devc->unit = SR_UNIT_CELSIUS;
                                devc->scale *= 0.01;
-                       } else if ((devc->scale1000 == 2)) {
+                       } else if (devc->scale1000 == 2) {
                                /* 16I Iso 500/1000V 3 GOhm */
                                devc->scale *= 0.1;
                        }