Skip to content

Commit

Permalink
nfc-emulate-uid: remove unreachable code and add proper cleaning when…
Browse files Browse the repository at this point in the history
… interrupted
  • Loading branch information
doegox committed Mar 4, 2014
1 parent db4fae9 commit 6ab3c36
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions examples/nfc-emulate-uid.c
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,10 @@ intr_hdlr(int sig)
if (pnd != NULL) {
printf("\nAborting current command...\n");
nfc_abort_command(pnd);
nfc_close(pnd);
}
nfc_exit(context);
exit(EXIT_SUCCESS);
}

static void
Expand Down Expand Up @@ -237,7 +240,4 @@ main(int argc, char *argv[])
}
}
}
nfc_close(pnd);
nfc_exit(context);
exit(EXIT_SUCCESS);
}

0 comments on commit 6ab3c36

Please sign in to comment.