From 44c650220a40053a2bcdf8705f5e19367b758c98 Mon Sep 17 00:00:00 2001 From: joerg_wunsch Date: Thu, 15 Sep 2011 20:08:15 +0000 Subject: [PATCH] Remove stray printf()s by fprintf(stderr). git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk/avrdude@1015 81a1dc3b-b13d-400b-aceb-764788c761c2 --- ChangeLog | 5 +++++ avrftdi.c | 9 +++++---- usbtiny.c | 4 +++- 3 files changed, 13 insertions(+), 5 deletions(-) diff --git a/ChangeLog b/ChangeLog index 02e131a5..3eccb524 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2011-09-15 Joerg Wunsch + + * avrftdi.c: Remove stray printf()s by fprintf(stderr) + * usbtiny.c: (Ditto.) + 2011-09-15 Joerg Wunsch * main.c: Restrict the cyclecounter readout to those cases where diff --git a/avrftdi.c b/avrftdi.c index cd9bdc7d..653a46a1 100644 --- a/avrftdi.c +++ b/avrftdi.c @@ -145,7 +145,8 @@ static int add_pin(PROGRAMMER *pgm, int pinfunc) else if(TYPE_2232H == ftype) mlim=15; else{ - printf("Unknown type %d (0x%x)\n",ftype,ftype); + fprintf(stderr, "Unknown type %d (0x%x)\n", + ftype, ftype); mlim=15; } /* check that the pin number is in range */ @@ -205,8 +206,8 @@ static int add_pins(PROGRAMMER *pgm, int pinfunc) else if (TYPE_2232H == ftype) mlim = 16; else{ - printf("Unknown type %d (0x%x)\n", - ftype, ftype); + fprintf(stderr, "Unknown type %d (0x%x)\n", + ftype, ftype); mlim = 16; } if (mask >= 1 << mlim) { @@ -262,7 +263,7 @@ static int write_flush(void) #endif if (verbose > 3) - printf("FTDI LOG: %02x %02x %02x %02x %02x %02x\n", + fprintf(stderr, "FTDI LOG: %02x %02x %02x %02x %02x %02x\n", buf[0], buf[1], buf[2], buf[3], buf[4], buf[5]); /* we need to flush here, because set_pin is used as reset. diff --git a/usbtiny.c b/usbtiny.c index afc7fe29..7fe8c857 100644 --- a/usbtiny.c +++ b/usbtiny.c @@ -226,7 +226,9 @@ static int usbtiny_open(PROGRAMMER* pgm, char* name) if (dev->descriptor.idVendor == USBTINY_VENDOR && dev->descriptor.idProduct == USBTINY_PRODUCT ) { // found match? if(verbose) - printf("avrdude: usbdev_open(): Found USBtinyISP, bus:device: %s:%s\n", bus->dirname, dev->filename); + fprintf(stderr, + "%s: usbdev_open(): Found USBtinyISP, bus:device: %s:%s\n", + progname, bus->dirname, dev->filename); // if -P was given, match device by device name and bus name if(name != NULL && (NULL == dev_name ||