]> sigrok.org Git - libsigrok.git/commitdiff
rs9lcd: Fix compiler warning.
authorUwe Hermann <redacted>
Mon, 31 Dec 2012 19:58:14 +0000 (20:58 +0100)
committerUwe Hermann <redacted>
Mon, 31 Dec 2012 19:58:14 +0000 (20:58 +0100)
rs9lcd.c:289:19: warning: 'rawval' may be used uninitialized in this
function [-Wmaybe-uninitialized]

hardware/common/dmm/rs9lcd.c

index 25e330705c1d6beee6a5793a9b15f76ff73b4a96..a86c9f20f5a0d1c498447421059671bdfa1203de 100644 (file)
@@ -262,7 +262,7 @@ static uint8_t decode_digit(uint8_t raw_digit)
 
 static double lcd_to_double(const struct rs9lcd_packet *rs_packet, int type)
 {
-       double rawval, multiplier = 1;
+       double rawval = 0, multiplier = 1;
        uint8_t digit, raw_digit;
        gboolean dp_reached = FALSE;
        int i, end;