Check -U option for unknown memories during parsing

$ avrdude -qp ATmega2560 -c usbtiny -U flesh:w:blink-mega2560+lext-test.hex:i
avrdude: unknown memory type flesh
avrdude: error parsing update operation 'flesh:w:blink-mega2560+lext-test.hex:i'
This commit is contained in:
Stefan Rueger
2022-08-03 00:04:14 +01:00
parent 42c8169c37
commit 9604a3ef36
3 changed files with 8 additions and 2 deletions

View File

@@ -1253,7 +1253,7 @@ void avr_add_mem_order(const char *str) {
exit(1);
}
int avr_known_mem(const char *str) {
int avr_mem_is_known(const char *str) {
for(size_t i=0; i < sizeof avr_mem_order/sizeof *avr_mem_order; i++)
if(avr_mem_order[i] && !strcmp(avr_mem_order[i], str))
return 1;