]> sigrok.org Git - libsigrok.git/commitdiff
Revert "baylibre-acme: Fix a compiler warning."
authorBartosz Golaszewski <redacted>
Mon, 13 Apr 2015 09:44:13 +0000 (11:44 +0200)
committerUwe Hermann <redacted>
Fri, 17 Apr 2015 14:42:36 +0000 (16:42 +0200)
This reverts commit 4cd97e5ad7bb63cb90d209506464fafd9f9eef8a.

We should actually check the return value of sr_gpio_setval_export().

Signed-off-by: Bartosz Golaszewski <redacted>
src/hardware/baylibre-acme/protocol.c

index 86fe020b345115690f903345392b38288e5ebe68..d0552553feffbebdb298cba9c1c848e0d87de1e8 100644 (file)
@@ -414,6 +414,7 @@ SR_PRIV int bl_acme_set_power_off(const struct sr_channel_group *cg,
                                  gboolean off)
 {
        struct channel_group_priv *cgp;
+       int val;
 
        cgp = cg->priv;
 
@@ -422,7 +423,7 @@ SR_PRIV int bl_acme_set_power_off(const struct sr_channel_group *cg,
                return SR_ERR_ARG;
        }
 
-       sr_gpio_setval_export(pws_gpios[cgp->index], off ? 0 : 1);
+       val = sr_gpio_setval_export(pws_gpios[cgp->index], off ? 0 : 1);
 
        return SR_OK;
 }