On Thu, Nov 28, 2013 at 3:28 PM, Andrew Makhorin <[email protected]> wrote: >> I further bisected the issue and found that the problem appears >> between GLPK versions 4.50 and 4.51: > > In 4.51 I replaced zlib 1.2.5 with zlib 1.2.7; probably something is > wrong with zlib 1.2.7 on 64-bit platform (see below). > > Could you please remove subdirectory glpk-4.52/src/zlib, copy there > subdirectory glpk-4.50/src/zlib, and then build glpk 4.52 from scratch? > I think the bug should disappear (since you report that 4.50 works > fine). Thank you.
Yes, that fixes the problem. It is also fixed in zlib 1.2.8 apparently: I just substituted the src/zlib dir in glpk with the one from zlib-1.2.8 and removed the liglpk_la-zio.o target from src/Makefile and it seems to work (note: I only checked with my small test file). > > > Andrew Makhorin > > >> >>> Reading problem data from `greenbea.gz'... >> >>> ==28394== Invalid read of size 8 >> >>> ==28394== at 0x4EE393C: zlib_crc32 (crc32.c:259) > > Here crc32.c attempts to read data from crc_table via DOLIT32 defined as > follows: > > #define DOLIT4 c ^= *buf4++; \ > c = crc_table[3][c & 0xff] ^ crc_table[2][(c >> 8) & 0xff] ^ \ > crc_table[1][(c >> 16) & 0xff] ^ crc_table[0][c >> 24] > #define DOLIT32 DOLIT4; DOLIT4; DOLIT4; DOLIT4; DOLIT4; DOLIT4; DOLIT4; > DOLIT4 > > The statement 'c ^= *buf4++;' is not portable, because c is declared as > a 32-bit int while buf4 is a pointer. > >> >>> ==28394== by 0x4EEA819: zlib_inflate (inflate.c:1232) >> >>> ==28394== by 0x4EE791F: gz_decomp (gzread.c:189) >> >>> ==28394== by 0x4EE7AE5: gz_fetch (gzread.c:245) >> >>> ==28394== by 0x4EE7CB7: zlib_gzread (gzread.c:339) >> >>> ==28394== by 0x4EE7DD2: zlib_gzgetc (gzread.c:398) >> >>> ==28394== by 0x4E61494: _glp_lib_xfgetc (glpenv07.c:580) >> >>> ==28394== by 0x4E9F70E: read_char (glpmps.c:167) >> >>> ==28394== by 0x4E9FCC2: indicator (glpmps.c:214) >> >>> ==28394== by 0x4EA0170: glp_read_mps (glpmps.c:395) >> >>> ==28394== by 0x400767: main (in /home/carlo/tmp/glpktst) >> >>> ==28394== Address 0x6aeb39f4b68 is not stack'd, malloc'd or >> >>> (recently) free'd >> >>> ==28394== >> >>> ==28394== >> >>> ==28394== Process terminating with default action of signal 11 >> >>> (SIGSEGV) > > _______________________________________________ Bug-glpk mailing list [email protected] https://lists.gnu.org/mailman/listinfo/bug-glpk
