X-Git-Url: https://git.rohieb.name/openwrt.git/blobdiff_plain/ab09debb66b84bcf763fa475feb80420232df791..85545a1d5a01821af290e54c7efbfc05d5a1d6f7:/package/gpioctl/src/main.c?ds=inline diff --git a/package/gpioctl/src/main.c b/package/gpioctl/src/main.c index 9aa317350..8ad27749b 100644 --- a/package/gpioctl/src/main.c +++ b/package/gpioctl/src/main.c @@ -63,7 +63,7 @@ main(int argc, char **argv) } else if (!strcmp(argv[1], "get")) { result = ioctl(fd, GPIO_GET, gpio_pin); - printf("Pin %d is %s\n", (result ? "HIGH" : "LOW")); + printf("Pin %d is %s\n", gpio_pin, (result ? "HIGH" : "LOW")); } else if (!strcmp(argv[1], "set")) { ioctl(fd, GPIO_SET, gpio_pin);