gpio.c: add pin number to export fail message
authorBrendan Le Foll <brendan.le.foll@intel.com>
Wed, 28 Jan 2015 13:00:20 +0000 (13:00 +0000)
committerBrendan Le Foll <brendan.le.foll@intel.com>
Wed, 28 Jan 2015 13:00:20 +0000 (13:00 +0000)
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
src/gpio/gpio.c

index fb125c9..a02e8d0 100644 (file)
@@ -132,7 +132,7 @@ mraa_gpio_init_raw(int pin)
         }
         length = snprintf(bu, sizeof(bu), "%d", dev->pin);
         if (write(export, bu, length*sizeof(char)) == -1) {
-            syslog(LOG_ERR, "gpio: Failed to write to export");
+            syslog(LOG_ERR, "gpio: Failed to write %d to export", dev->pin);
             close(export);
             free(dev);
             return NULL;