From: Uwe Bonnes Date: Wed, 8 Sep 2010 14:10:41 +0000 (+0200) Subject: Remove dead code. X-Git-Tag: v1.0rc1~133^2~123 X-Git-Url: http://developer.intra2net.com/git/?p=libftdi;a=commitdiff_plain;h=f5b8b5b3b28340d1ae710a8d2af0192ab1d28a02;hp=f2cd9fd5d8cac4ca8c94e4f5e6560b4967c87be5 Remove dead code. --- diff --git a/src/ftdi.c b/src/ftdi.c index 5a27ac3..bb8ec4b 100644 --- a/src/ftdi.c +++ b/src/ftdi.c @@ -2505,23 +2505,6 @@ int ftdi_eeprom_decode(struct ftdi_context *ftdi, unsigned char *buf, int size) if(ftdi->type == TYPE_R) eeprom_size = 0x80; eeprom = ftdi->eeprom; -#if 0 - size_check = eeprom->size; - size_check -= 28; // 28 are always in use (fixed) - - // Top half of a 256byte eeprom is used just for strings and checksum - // it seems that the FTDI chip will not read these strings from the lower half - // Each string starts with two bytes; offset and type (0x03 for string) - // the checksum needs two bytes, so without the string data that 8 bytes from the top half - if (eeprom->size>=256)size_check = 120; - size_check -= manufacturer_size*2; - size_check -= product_size*2; - size_check -= serial_size*2; - - // eeprom size exceeded? - if (size_check < 0) - ftdi_error_return(-1,"Size check failed"); -#endif // empty eeprom struct memset(eeprom, 0, sizeof(struct ftdi_eeprom));