]> sigrok.org Git - libsigrok.git/commitdiff
victor-dmm: Fix compiler warning.
authorUwe Hermann <redacted>
Mon, 31 Dec 2012 20:03:45 +0000 (21:03 +0100)
committerUwe Hermann <redacted>
Mon, 31 Dec 2012 20:03:45 +0000 (21:03 +0100)
protocol.c:106:10: warning: 'factor' may be used uninitialized in this
function [-Wmaybe-uninitialized]

hardware/victor-dmm/protocol.c

index e2c05b02ffa5d7b2e3ade53bffcf4dc9e0c9e09b..6a82d339756807b613691483df48f31108026b4b 100644 (file)
@@ -70,6 +70,7 @@ static void decode_buf(struct dev_context *devc, unsigned char *data)
        }
 
        /* Decimal point position */
+       factor = 0;
        switch (data[7] >> 4) {
        case 0x00:
                factor = 0;