From c42e8d60d59bc6716cca51cc645fccf31c9953b5 Mon Sep 17 00:00:00 2001 From: Manuel Reimer Date: Thu, 7 Jan 2021 16:17:27 +0100 Subject: Fix compiler warnings in lcdtestpattern - "delay" is not needed and was never used - "endless" was never implemented and can easily be done with an endless loop on your shell --- tools/lcdtestpattern/lcdtestpattern.c | 11 +---------- 1 file changed, 1 insertion(+), 10 deletions(-) diff --git a/tools/lcdtestpattern/lcdtestpattern.c b/tools/lcdtestpattern/lcdtestpattern.c index 6e9e067..98609dd 100644 --- a/tools/lcdtestpattern/lcdtestpattern.c +++ b/tools/lcdtestpattern/lcdtestpattern.c @@ -66,7 +66,6 @@ void usage() fprintf(stdout, " -d --display specifies the output display (default is the first one)\n"); fprintf(stdout, " -u --upsidedown rotates the output by 180 degrees (default: no)\n"); fprintf(stdout, " -i --invert inverts the output (default: no)\n"); - fprintf(stdout, " -e --endless show all images in endless loop (default: no)\n"); fprintf(stdout, " -s --sleep set sleeptime between two patterns [ms] (default: %d ms)\n", kDefaultSleepMs); fprintf(stdout, " -b --brightness set brightness for display if driver support it [%%]\n"); fprintf(stdout, " (default: config file value)\n"); @@ -84,7 +83,6 @@ int main(int argc, char *argv[]) {"config", required_argument, NULL, 'c'}, {"display", required_argument, NULL, 'd'}, {"sleep", required_argument, NULL, 's'}, - {"endless", no_argument, NULL, 'e'}, {"upsidedown", no_argument, NULL, 'u'}, {"invert", no_argument, NULL, 'i'}, {"brightness", required_argument, NULL, 'b'}, @@ -96,13 +94,11 @@ int main(int argc, char *argv[]) bool upsideDown = false; bool invert = false; int brightness = -1; - bool delay = false; int sleepMs = kDefaultSleepMs; - bool endless = false; unsigned int displayNumber = 0; int c, option_index = 0; - while ((c = getopt_long(argc, argv, "c:d:s:euib:", long_options, &option_index)) != -1) + while ((c = getopt_long(argc, argv, "c:d:s:uib:", long_options, &option_index)) != -1) { switch(c) { @@ -124,11 +120,6 @@ int main(int argc, char *argv[]) case 's': sleepMs = atoi(optarg); - delay = true; - break; - - case 'e': - endless = true; break; case 'b': -- cgit v1.2.3