bug #26412: avrdude segfaults when called with a programmer that does not
support it Do not call pgm->perform_osccal() unless it is != 0. git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk@822 81a1dc3b-b13d-400b-aceb-764788c761c2
This commit is contained in:
parent
9161daeaa1
commit
141a19049a
|
@ -1,3 +1,9 @@
|
||||||
|
2009-07-01 Joerg Wunsch <j.gnu@uriah.heep.sax.de>
|
||||||
|
|
||||||
|
bug #26412: avrdude segfaults when called with a programmer that does not
|
||||||
|
support it
|
||||||
|
* main.c: do not call pgm->perform_osccal() unless it is != 0.
|
||||||
|
|
||||||
2009-06-24 Joerg Wunsch <j.gnu@uriah.heep.sax.de>
|
2009-06-24 Joerg Wunsch <j.gnu@uriah.heep.sax.de>
|
||||||
|
|
||||||
Contributed by Zoltan Laday:
|
Contributed by Zoltan Laday:
|
||||||
|
|
|
@ -26,6 +26,7 @@ Current:
|
||||||
|
|
||||||
* Major Xmega fixes for the JTAG ICE mkII (patch #6825)
|
* Major Xmega fixes for the JTAG ICE mkII (patch #6825)
|
||||||
|
|
||||||
|
* Bugfixes.
|
||||||
|
|
||||||
Version 5.6:
|
Version 5.6:
|
||||||
|
|
||||||
|
|
|
@ -786,8 +786,15 @@ int main(int argc, char * argv [])
|
||||||
* perform an RC oscillator calibration
|
* perform an RC oscillator calibration
|
||||||
* as outlined in appnote AVR053
|
* as outlined in appnote AVR053
|
||||||
*/
|
*/
|
||||||
|
if (pgm->perform_osccal == 0) {
|
||||||
|
fprintf(stderr,
|
||||||
|
"%s: programmer does not support RC oscillator calibration\n",
|
||||||
|
progname);
|
||||||
|
exitrc = 1;
|
||||||
|
} else {
|
||||||
fprintf(stderr, "%s: performing RC oscillator calibration\n", progname);
|
fprintf(stderr, "%s: performing RC oscillator calibration\n", progname);
|
||||||
exitrc = pgm->perform_osccal(pgm);
|
exitrc = pgm->perform_osccal(pgm);
|
||||||
|
}
|
||||||
if (exitrc == 0 && quell_progress < 2) {
|
if (exitrc == 0 && quell_progress < 2) {
|
||||||
fprintf(stderr,
|
fprintf(stderr,
|
||||||
"%s: calibration value is now stored in EEPROM at address 0\n",
|
"%s: calibration value is now stored in EEPROM at address 0\n",
|
||||||
|
|
Loading…
Reference in New Issue