diff --git a/src/libavrdude.h b/src/libavrdude.h index 453b22a0..60cf4ebf 100644 --- a/src/libavrdude.h +++ b/src/libavrdude.h @@ -59,6 +59,7 @@ typedef uint32_t pinmask_t; #define LIBAVRDUDE_NOTSUPPORTED (-2) // operation not supported #define LIBAVRDUDE_SOFTFAIL (-3) // returned, eg, by avr_signature() if caller // might proceed with chip erase +#define LIBAVRDUDE_EXIT (-4) // End all operations in this session /* formerly lists.h */ diff --git a/src/wiring.c b/src/wiring.c index caac6bbe..798db2a3 100644 --- a/src/wiring.c +++ b/src/wiring.c @@ -109,7 +109,7 @@ static int wiring_parseextparms(const PROGRAMMER *pgm, const LISTID extparms) { msg_error(" -xsnooze= Wait snooze [ms] before protocol sync after port open\n"); msg_error(" -xdelay= Add delay [ms] after reset, can be negative\n"); msg_error(" -xhelp Show this help menu and exit\n"); - exit(0); + return LIBAVRDUDE_EXIT;; } pmsg_error("invalid extended parameter '%s'\n", extended_param);