diff --git a/examples/mifare-classic-format.c b/examples/mifare-classic-format.c index b6d2c06..ed0dbb6 100644 --- a/examples/mifare-classic-format.c +++ b/examples/mifare-classic-format.c @@ -161,7 +161,7 @@ main(int argc, char *argv[]) } } // Remaining args, if any, are in argv[optind .. (argc-1)] - + memcpy(default_keys, default_keys_int, sizeof(default_keys_int)); if ((argc - optind) > 0) diff --git a/examples/mifare-classic-read-ndef.c b/examples/mifare-classic-read-ndef.c index 3c6d899..17388b8 100644 --- a/examples/mifare-classic-read-ndef.c +++ b/examples/mifare-classic-read-ndef.c @@ -239,7 +239,7 @@ error: freefare_free_tags (tags); nfc_close (device); } - + nfc_exit (context); exit (error); } diff --git a/examples/mifare-classic-write-ndef.c b/examples/mifare-classic-write-ndef.c index 76bc308..5482a94 100644 --- a/examples/mifare-classic-write-ndef.c +++ b/examples/mifare-classic-write-ndef.c @@ -203,7 +203,7 @@ main(int argc, char *argv[]) nfc_connstring devices[8]; size_t device_count; - + nfc_context *context; nfc_init (&context); if (context == NULL) diff --git a/examples/mifare-desfire-create-ndef.c b/examples/mifare-desfire-create-ndef.c index 1401cb8..f1f00cd 100644 --- a/examples/mifare-desfire-create-ndef.c +++ b/examples/mifare-desfire-create-ndef.c @@ -105,7 +105,7 @@ main(int argc, char *argv[]) for (size_t d = 0; d < device_count; d++) { device = nfc_open (context, devices[d]); - + if (!device) { warnx ("nfc_open() failed."); error = EXIT_FAILURE; diff --git a/examples/mifare-desfire-ev1-configure-default-key.c b/examples/mifare-desfire-ev1-configure-default-key.c index 79df745..134a913 100644 --- a/examples/mifare-desfire-ev1-configure-default-key.c +++ b/examples/mifare-desfire-ev1-configure-default-key.c @@ -72,7 +72,7 @@ main(int argc, char *argv[]) nfc_connstring devices[8]; size_t device_count; - + nfc_context *context; nfc_init (&context); if (context == NULL) diff --git a/examples/mifare-desfire-ev1-configure-random-uid.c b/examples/mifare-desfire-ev1-configure-random-uid.c index 847233e..d6a0045 100644 --- a/examples/mifare-desfire-ev1-configure-random-uid.c +++ b/examples/mifare-desfire-ev1-configure-random-uid.c @@ -82,7 +82,7 @@ main(int argc, char *argv[]) nfc_connstring devices[8]; size_t device_count; - + nfc_context *context; nfc_init (&context); if (context == NULL) diff --git a/examples/mifare-desfire-format.c b/examples/mifare-desfire-format.c index 6ba0c5b..9996930 100644 --- a/examples/mifare-desfire-format.c +++ b/examples/mifare-desfire-format.c @@ -82,7 +82,7 @@ main(int argc, char *argv[]) nfc_connstring devices[8]; size_t device_count; - + nfc_context *context; nfc_init (&context); if (context == NULL) diff --git a/examples/mifare-desfire-info.c b/examples/mifare-desfire-info.c index dedce56..9f55eaa 100644 --- a/examples/mifare-desfire-info.c +++ b/examples/mifare-desfire-info.c @@ -36,7 +36,7 @@ main(int argc, char *argv[]) nfc_connstring devices[8]; size_t device_count; - + nfc_context *context; nfc_init (&context); if (context == NULL) diff --git a/examples/mifare-desfire-read-ndef.c b/examples/mifare-desfire-read-ndef.c index 0771adc..687e230 100644 --- a/examples/mifare-desfire-read-ndef.c +++ b/examples/mifare-desfire-read-ndef.c @@ -121,7 +121,7 @@ main(int argc, char *argv[]) nfc_connstring devices[8]; size_t device_count; - + nfc_context *context; nfc_init (&context); if (context == NULL) @@ -133,7 +133,7 @@ main(int argc, char *argv[]) for (size_t d = 0; d < device_count; d++) { device = nfc_open (context, devices[d]); - + if (!device) { warnx ("nfc_open() failed."); error = EXIT_FAILURE; diff --git a/examples/mifare-desfire-write-ndef.c b/examples/mifare-desfire-write-ndef.c index abe2df4..1b36af4 100644 --- a/examples/mifare-desfire-write-ndef.c +++ b/examples/mifare-desfire-write-ndef.c @@ -150,7 +150,7 @@ main(int argc, char *argv[]) nfc_connstring devices[8]; size_t device_count; - + nfc_context *context; nfc_init (&context); if (context == NULL) @@ -162,7 +162,7 @@ main(int argc, char *argv[]) for (size_t d = 0; d < device_count; d++) { device = nfc_open (context, devices[d]); - + if (!device) { warnx ("nfc_open() failed."); error = EXIT_FAILURE; diff --git a/libfreefare/freefare_internal.h b/libfreefare/freefare_internal.h index 3ddf3c9..5ad81e1 100644 --- a/libfreefare/freefare_internal.h +++ b/libfreefare/freefare_internal.h @@ -269,7 +269,7 @@ struct mifare_ultralight_tag { #define ASSERT_MIFARE_ULTRALIGHT_C(tag) do { if (! IS_MIFARE_ULTRALIGHT_C(tag)) return errno = ENODEV, -1; } while (0) /* - * FreefareTag cast macros + * FreefareTag cast macros * * This macros are intended to provide a convenient way to cast abstract * FreefareTag structures to concrete Tags (e.g. MIFARE Classic tag). diff --git a/test/mifare_classic_fixture.c b/test/mifare_classic_fixture.c index 51ed076..c02238f 100644 --- a/test/mifare_classic_fixture.c +++ b/test/mifare_classic_fixture.c @@ -32,7 +32,7 @@ cut_setup (void) int res; nfc_connstring devices[8]; size_t device_count; - + nfc_init (&context); cut_assert_not_null (context, cut_message ("Unable to init libnfc (malloc)")); @@ -42,7 +42,7 @@ cut_setup (void) for (size_t i = 0; i < device_count; i++) { device = nfc_open (context, devices[i]); - if (!device) + if (!device) cut_omit ("nfc_open() failed."); tags = freefare_get_tags (device); @@ -79,7 +79,7 @@ cut_teardown (void) if (device) nfc_close (device); - + nfc_exit (context); } diff --git a/test/mifare_desfire_ev1_fixture.c b/test/mifare_desfire_ev1_fixture.c index 9152afb..6a96afe 100644 --- a/test/mifare_desfire_ev1_fixture.c +++ b/test/mifare_desfire_ev1_fixture.c @@ -32,7 +32,7 @@ cut_setup (void) int res; nfc_connstring devices[8]; size_t device_count; - + nfc_init (&context); cut_assert_not_null (context, cut_message ("Unable to init libnfc (malloc)")); @@ -43,7 +43,7 @@ cut_setup (void) for (size_t i = 0; i < device_count; i++) { device = nfc_open (context, devices[i]); - if (!device) + if (!device) cut_omit ("nfc_open() failed."); tags = freefare_get_tags (device); @@ -91,9 +91,9 @@ cut_teardown (void) tags = NULL; } - if (device) + if (device) nfc_close (device); - + nfc_exit (context); } diff --git a/test/mifare_desfire_fixture.c b/test/mifare_desfire_fixture.c index cdd46da..356ef3e 100644 --- a/test/mifare_desfire_fixture.c +++ b/test/mifare_desfire_fixture.c @@ -32,7 +32,7 @@ cut_setup (void) int res; nfc_connstring devices[8]; size_t device_count; - + nfc_init (&context); cut_assert_not_null (context, cut_message ("Unable to init libnfc (malloc)")); @@ -43,7 +43,7 @@ cut_setup (void) for (size_t i = 0; i < device_count; i++) { device = nfc_open (context, devices[i]); - if (!device) + if (!device) cut_omit ("nfc_open() failed."); tags = freefare_get_tags (device); @@ -88,7 +88,7 @@ cut_teardown (void) if (device) nfc_close (device); - + nfc_exit (context); } diff --git a/test/mifare_ultralight_fixture.c b/test/mifare_ultralight_fixture.c index 2f8567b..025417e 100644 --- a/test/mifare_ultralight_fixture.c +++ b/test/mifare_ultralight_fixture.c @@ -32,7 +32,7 @@ cut_setup (void) int res; nfc_connstring devices[8]; size_t device_count; - + nfc_init (&context); cut_assert_not_null (context, cut_message ("Unable to init libnfc (malloc)")); @@ -43,7 +43,7 @@ cut_setup (void) for (size_t i = 0; i < device_count; i++) { device = nfc_open (context, devices[i]); - if (!device) + if (!device) cut_omit ("nfc_open() failed."); tags = freefare_get_tags (device); @@ -81,7 +81,7 @@ cut_teardown (void) if (device) nfc_close (device); - + nfc_exit (context); }