mraa-uart.c: Remove impossible condition with a fprintf
Thanks to @pylbert for the spot Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
This commit is contained in:
@@ -156,10 +156,6 @@ main(int argc, const char** argv) {
|
|||||||
} else {
|
} else {
|
||||||
for (i=1; i<argc; i++) {
|
for (i=1; i<argc; i++) {
|
||||||
if (!strcmp(argv[i], "dev")) {
|
if (!strcmp(argv[i], "dev")) {
|
||||||
if (argc <= 1) {
|
|
||||||
fprintf(stderr, "%s : dev needs uart device as argument\n", argv[0]);
|
|
||||||
break;
|
|
||||||
} else {
|
|
||||||
uart = uarttool_find(argv[i+1]);
|
uart = uarttool_find(argv[i+1]);
|
||||||
if (uart == NULL) {
|
if (uart == NULL) {
|
||||||
fprintf(stderr, "%s : cannot find uart %s\n", argv[0], argv[i+1]);
|
fprintf(stderr, "%s : cannot find uart %s\n", argv[0], argv[i+1]);
|
||||||
@@ -170,7 +166,6 @@ main(int argc, const char** argv) {
|
|||||||
if (res != MRAA_SUCCESS) {
|
if (res != MRAA_SUCCESS) {
|
||||||
fprintf(stderr, "warning: problems accessing uart settings, attempting to continue\n");
|
fprintf(stderr, "warning: problems accessing uart settings, attempting to continue\n");
|
||||||
}
|
}
|
||||||
}
|
|
||||||
} else
|
} else
|
||||||
|
|
||||||
/* Baudrate setting */
|
/* Baudrate setting */
|
||||||
|
|||||||
Reference in New Issue
Block a user