nfc-relay-picc: fix wrong open mode for file descriptor

Fixes #280
This commit is contained in:
Romuald Conty 2015-04-30 14:33:59 +02:00
parent 8fbedb87f5
commit 33ce39ff71

View file

@ -226,7 +226,7 @@ main(int argc, char *argv[])
nfc_exit(context);
exit(EXIT_FAILURE);
}
if ((fd4 = fdopen(4, "r")) == NULL) {
if ((fd4 = fdopen(4, "w")) == NULL) {
ERR("Could not open file descriptor 4");
nfc_exit(context);
exit(EXIT_FAILURE);