Messages in this thread | | | Date | Tue, 12 Aug 2008 10:39:16 -0500 | From | Beverly Seavey <> | Subject | fscanf changes value when reading . cc version 4.1.2 20071124 (Red Hat 4.1.2-42) |
| |
hornbill% 10:36>g++ -v Using built-in specs. Target: i386-redhat-linux Configured with: ../configure --prefix=/usr --mandir=/usr/share/man --infodir=/usr/share/info --enable-shared --enable-threads=posix --enable-checking=release --with-system-zlib --enable-__cxa_atexit --disable-libunwind-exceptions --enable-libgcj-multifile --enable-languages=c,c++,objc,obj-c++,java,fortran,ada --enable-java-awt=gtk --disable-dssi --enable-plugin --with-java-home=/usr/lib/jvm/java-1.4.2-gcj-1.4.2.0/jre --with-cpu=generic --host=i386-redhat-linux Thread model: posix gcc version 4.1.2 20071124 (Red Hat 4.1.2-42) hornbill% 10:36>
(gdb) watch *(allLeavesUpperBounds + 12) Hardware watchpoint 1: *(allLeavesUpperBounds + 12) (gdb) run Starting program: /v/v03/s/seavey/private/condStuff/apD14L14-S07-75751_S04-1616-100f-NF Hardware watchpoint 1: *(allLeavesUpperBounds + 12) Hardware watchpoint 1: *(allLeavesUpperBounds + 12) Hardware watchpoint 1: *(allLeavesUpperBounds + 12) Hardware watchpoint 1: *(allLeavesUpperBounds + 12) Hardware watchpoint 1: *(allLeavesUpperBounds + 12) Hardware watchpoint 1: *(allLeavesUpperBounds + 12)
Old value = 0 <<<<<<<<<<<<<<< this I did New value = 1 0x00546231 in _IO_vfscanf_internal () from /lib/libc.so.6 (gdb) cont Continuing. Hardware watchpoint 1: *(allLeavesUpperBounds + 12)
Old value = 1 New value = 0 <<<<<<<<<<<<<<< fscanf did this 0x00546231 in _IO_vfscanf_internal () from /lib/libc.so.6 (gdb) where #0 0x00546231 in _IO_vfscanf_internal () from /lib/libc.so.6 #1 0x00547b33 in vfscanf () from /lib/libc.so.6 #2 0x0054c612 in fscanf () from /lib/libc.so.6 #3 0x0804b7e2 in readCompiled (readParamsPtr=0x870f070, treeCtr=14, numLeaves=1, allTreesLowerBounds=0x804efa0, allTreesUpperBounds=0x8050bc0) at apD14L14-S07-75751_S04-1616-100f-NF.c:880 #4 0x0804c230 in main () at apD14L14-S07-75751_S04-1616-100f-NF.c:423 (gdb)
| |