comparison miscutil/srec-regions.c @ 624:7485e75d9477

srec-regions: removed unnecessary prohibition against address going backward
author Mychaela Falconia <falcon@freecalypso.org>
date Thu, 27 Feb 2020 08:12:11 +0000
parents 89e9e79a7f55
children 7ef3343161d6
comparison
equal deleted inserted replaced
623:46d17c346511 624:7485e75d9477
151 region_start = curaddr; 151 region_start = curaddr;
152 region_end = curaddr + datalen; 152 region_end = curaddr + datalen;
153 state = 2; 153 state = 2;
154 continue; 154 continue;
155 } 155 }
156 if (curaddr < region_end) { 156 if (curaddr != region_end) {
157 fprintf(stderr,
158 "%s line %d: address going backwards\n",
159 infname, lineno);
160 exit(1);
161 }
162 if (curaddr > region_end) {
163 printf("0x%08lX to 0x%08lX (%lu bytes)\n", 157 printf("0x%08lX to 0x%08lX (%lu bytes)\n",
164 region_start, region_end, 158 region_start, region_end,
165 region_end - region_start); 159 region_end - region_start);
166 region_start = curaddr; 160 region_start = curaddr;
167 } 161 }