Fix -Wshadow warning: tools/nciattach.c: In function ‘main’: tools/nciattach.c:272:9: error: declaration of ‘opt’ shadows a previous local [-Werror=shadow] 272 | char *opt; | ^~~ tools/nciattach.c:236:24: note: shadowed declaration is here 236 | int detach, printpid, opt, i, n, ld, err; | ^~~ Signed-off-by: Krzysztof Kozlowski --- tools/nciattach.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/tools/nciattach.c b/tools/nciattach.c index 574c0fbe784a..4ac37d82d545 100644 --- a/tools/nciattach.c +++ b/tools/nciattach.c @@ -269,16 +269,16 @@ int main(int argc, char *argv[]) } for (n = 0; optind < argc; n++, optind++) { - char *opt; + char *option; - opt = argv[optind]; + option = argv[optind]; switch(n) { case 0: dev[0] = 0; - if (!strchr(opt, '/')) + if (!strchr(option, '/')) strcpy(dev, "/dev/"); - strcat(dev, opt); + strcat(dev, option); break; case 1: -- 2.27.0 _______________________________________________ Linux-nfc mailing list -- linux-nfc@lists.01.org To unsubscribe send an email to linux-nfc-leave@lists.01.org %(web_page_url)slistinfo%(cgiext)s/%(_internal_name)s