diff --git a/client/proxmark3.c b/client/proxmark3.c index 480f39fa3..1d3a0e8b5 100644 --- a/client/proxmark3.c +++ b/client/proxmark3.c @@ -503,6 +503,9 @@ int main(int argc, char *argv[]) { CloseProxmark(); } + if ((port != NULL) && (!session.pm3_present)) + exit(EXIT_FAILURE); + if (!session.pm3_present) PrintAndLogEx(INFO, "Running in " _YELLOW_("OFFLINE") "mode. Check \"%s -h\" if it's not what you want.\n", exec_name); @@ -531,5 +534,5 @@ int main(int argc, char *argv[]) { CloseProxmark(); } - exit(0); + exit(EXIT_SUCCESS); }