clang warning:
arygon.c:115:118: warning: data argument not used by format string
[-Wformat-extra-args]
..."%s", "Trying to find ARYGON device on serial port: %s at %d bauds.", acPort,...
~~~~ ^
1 warning generated.
getline() is no more used. So no need to use this ugly hack.
This also solves a compiler warning;
In file included from ../libnfc/log.h:22:0,
from ../libnfc/chips/pn53x-internal.h:28,
from ../libnfc/chips/pn53x.h:31,
from pn53x-tamashell.c:68:
../config.h:153:0: warning: "_XOPEN_SOURCE" redefined [enabled by default]
/usr/include/features.h:165:0: note: this is the location of the previous definition
In file included from nfc-internal.c:26:
nfc-internal.h:111:5: warning: "_BYTE_ORDER" is not defined
nfc-internal.h:111:20: warning: "_LITTLE_ENDIAN" is not defined
pn532_uart.c:151: warning: no previous prototype for ‘pn532_connstring_decode’
pn532_uart.c:491: warning: no previous prototype for ‘pn532_uart_abort_command’
pn53x_usb.c:94: warning: no previous prototype for ‘pn53x_usb_bulk_read’
pn53x_usb.c:107: warning: no previous prototype for ‘pn53x_usb_bulk_write’
pn53x_usb.c:139: warning: no previous prototype for ‘pn53x_usb_get_device_model’
pn53x_usb.c:154: warning: no previous prototype for ‘pn53x_usb_get_end_points’
pn53x_usb.c:259: warning: no previous prototype for ‘pn53x_usb_connstring_decode’
pn53x_usb.c:713: warning: no previous prototype for ‘pn53x_usb_set_property_bool’
pn53x_usb.c:742: warning: no previous prototype for ‘pn53x_usb_abort_command’
arygon.c:174: warning: no previous prototype for ‘arygon_connstring_decode’
arygon.c:360: warning: no previous prototype for ‘arygon_abort’
arygon.c:545: warning: no previous prototype for ‘arygon_abort_command’
acr122s.c:422: warning: no previous prototype for ‘acr122s_connstring_decode’
acr122s.c:703: warning: no previous prototype for ‘acr122s_abort_command’
Fixes compiler warnings:
acr122_usb.c:90: warning: no previous prototype for ‘acr122_usb_bulk_read’
acr122_usb.c:107: warning: no previous prototype for ‘acr122_usb_bulk_write’
acr122_usb.c:140: warning: no previous prototype for ‘acr122_usb_get_device_model’
acr122_usb.c:155: warning: no previous prototype for ‘acr122_usb_get_end_points’
acr122_usb.c:252: warning: no previous prototype for ‘acr122_usb_connstring_decode’
acr122_usb.c:306: warning: no previous prototype for ‘acr122_usb_open’
acr122_usb.c:428: warning: no previous prototype for ‘acr122_usb_close’
acr122_usb.c:497: warning: no previous prototype for ‘acr122_build_frame’
acr122_usb.c:660: warning: no previous prototype for ‘acr122_usb_abort_command’
nfc-emulate-forum-tag4.c:117: warning: no previous prototype for ‘nfcforum_tag4_io’
nfc-emulate-forum-tag4.c:231: warning: no previous prototype for ‘stop_emulation’
nfc-emulate-forum-tag4.c:241: warning: no previous prototype for ‘ndef_message_load’
nfc-emulate-forum-tag4.c:269: warning: no previous prototype for ‘ndef_message_save’
nfc-emulate-forum-tag4.c:285: warning: no previous prototype for ‘usage’
nfc-read-forum-tag3.c:63: warning: no previous prototype for ‘print_usage’
nfc-read-forum-tag3.c:70: warning: no previous prototype for ‘stop_select’
nfc-read-forum-tag3.c:80: warning: no previous prototype for ‘build_felica_frame’
nfc-read-forum-tag3.c:91: warning: no previous prototype for ‘nfc_forum_tag_type3_check’
nfc-relay-picc.c:76: warning: no previous prototype for ‘intr_hdlr’
nfc-relay-picc.c:85: warning: no previous prototype for ‘print_usage’
nfc-relay-picc.c:96: warning: no previous prototype for ‘print_hex_fd4’
nfc-relay-picc.c:118: warning: no previous prototype for ‘scan_hex_fd3’
nfc-relay-picc.c: In function ‘main’:
nfc-relay-picc.c:190: warning: function declaration isn’t a prototype
nfc-emulate-forum-tag2.c:78: warning: no previous prototype for ‘stop_emulation’
nfc-emulate-forum-tag2.c:116: warning: no previous prototype for ‘nfcforum_tag2_io’
nfc-emulate-tag.c:65: warning: no previous prototype for ‘intr_hdlr’
nfc-emulate-tag.c:76: warning: no previous prototype for ‘target_io’
nfc-emulate-tag.c:139: warning: no previous prototype for ‘nfc_target_emulate_tag’
Fix compiler warnings:
pn53x-tamashell.c: In function ‘main’:
pn53x-tamashell.c:79: warning: nested extern declaration of ‘__stdinp’
pn53x-tamashell.c:79: warning: redundant redeclaration of ‘__stdinp’
/usr/include/stdio.h:164: warning: previous declaration of ‘__stdinp’
was here