diff --git a/avrdude/ChangeLog b/avrdude/ChangeLog
index 6b3747fc..6069b1ef 100644
--- a/avrdude/ChangeLog
+++ b/avrdude/ChangeLog
@@ -1,3 +1,8 @@
+2005-09-19  Joerg Wunsch <j@uriah.heep.sax.de>
+
+	* butterfly.c (butterfly_initialize): make the device code unsigned so
+	it wouldn't sign-extend when >= 0x80.
+
 2005-09-18  Joerg Wunsch <j@uriah.heep.sax.de>
 
 	Add the serial bit-bang driver, contributed by Michael Holzt.
diff --git a/avrdude/butterfly.c b/avrdude/butterfly.c
index 32809323..313b62ea 100644
--- a/avrdude/butterfly.c
+++ b/avrdude/butterfly.c
@@ -226,7 +226,7 @@ static int butterfly_initialize(PROGRAMMER * pgm, AVRPART * p)
   char hw[2];
   char buf[10];
   char type;
-  char c;
+  unsigned char c;
   int dev_supported = 0;
 
   no_show_func_info();