Update src/mfoc.c

This commit is contained in:
jarjar 2025-04-07 12:07:38 +00:00
parent ba072f16f6
commit edaaf90cbc

View File

@ -285,6 +285,7 @@ int main(int argc, char *const argv[])
case 0x01: case 0x01:
case 0x08: case 0x08:
case 0x88: case 0x88:
case 0x19:
if (get_rats_is_2k(t, r)) { if (get_rats_is_2k(t, r)) {
printf("Found Mifare Plus 2k tag\n"); printf("Found Mifare Plus 2k tag\n");
t.num_sectors = NR_TRAILERS_2k; t.num_sectors = NR_TRAILERS_2k;
@ -753,7 +754,7 @@ error:
exit(EXIT_FAILURE); exit(EXIT_FAILURE);
} }
void usage(FILE *stream, int errno) void usage(FILE *stream, int code)
{ {
fprintf(stream, "Usage: mfoc [-h] [-k key] [-f file] ... [-P probnum] [-T tolerance] [-O output]\n"); fprintf(stream, "Usage: mfoc [-h] [-k key] [-f file] ... [-P probnum] [-T tolerance] [-O output]\n");
fprintf(stream, "\n"); fprintf(stream, "\n");
@ -776,7 +777,7 @@ void usage(FILE *stream, int errno)
fprintf(stream, "\n"); fprintf(stream, "\n");
fprintf(stream, "This is mfoc version %s.\n", PACKAGE_VERSION); fprintf(stream, "This is mfoc version %s.\n", PACKAGE_VERSION);
fprintf(stream, "For more information, run: 'man mfoc'.\n"); fprintf(stream, "For more information, run: 'man mfoc'.\n");
exit(errno); exit(code);
} }
void mf_init(mfreader *r) void mf_init(mfreader *r)