nfc-tools / libfreefare

A convenience API for NFC cards manipulations on top of libnfc.
Other
396 stars 105 forks source link

Do not fail crypto error without reporting #60

Closed manu0401 closed 7 years ago

manu0401 commented 7 years ago

Add last_pcd_error value for some crypto errors. Also enable the warning even if WITH_DEBUG is not set, so that we have a clue of why it failed.

0001-Do-not-fail-crypto-error-without-reporting.patch.txt

smortex commented 7 years ago

Makes sense!

May I ask you to keep the message printing within the WITH_DEBUG condition (writing to stderr from a library is not so good, there are a few locations where it's done in the library unfortunately… feel free to correct this if you wish :wink:).

Also, can you please fill-in a Pull-Request so that we can benefit from GitHub's tools and review system?

Thanks!

manu0401 commented 7 years ago

I think I managed to do it (github documentation misses a few steps). https://github.com/nfc-tools/libfreefare/pull/61

smortex commented 7 years ago

Perfect, thanks!