Re: strange problem with self-compiled software on FC 5 T2...

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



John Reiser wrote:
>> Using gcc-3.5 on Debian-Sarge runs as expected, but on T2 and Rawhide j
>> is set to 0 after fscanf!!!
> 
> Run under gdb, put a breakpoint on fscanf, upon arrival put a watchpoint on j:
> 	(gdb) print &j
> 	(gdb) watch *(int *)0x....
> 	(gdb) continue
> 
>> double x, y, z, korr, SekundeSat;
>> long j, JahrSat;
> 
> It's conceivable that this is some fallout from the [impending ?] change
> to long double.  Note that 'j' is declared just after some 'double' locals,
> and "%lf" appears in the fscanf.
Changing those lines like this
"double x, y, z, korr, SekundeSat;
char d;
long j, JahrSat;"
works on my system. "d" is just some unused placeholder to put something
between double and long.

Here is my gdb-output, though I doubt I did it right. And I certainly
don't understand a single bit...

fscanf-rv: 6
(gdb) print &j
$1 = (long int *) 0xbfc34df0
(gdb) watch *(int *)0xbfc34df0
Hardware watchpoint 4: *(int *) 3217247728
(gdb) step
j nach fscanf: 0
(gdb) step
(gdb) step
(gdb) step
(gdb) step
(gdb) step
(gdb) step
Hardware watchpoint 4: *(int *) 3217247728

Old value = 0
New value = 1
0x080510d5 in leseDatenIGS (input=0x9c20170, daten=0x9c202e8) at
lese.cpp:206
/home/patrick/jamila/lese.cpp:206:5112:beg:0x80510d5
(gdb) step
(gdb) step
(gdb) step
(gdb) step
(gdb) step
j vor fscanf: 1
(gdb) step
Hardware watchpoint 4: *(int *) 3217247728

Old value = 1
New value = 0
0x0040c24f in _IO_vfscanf_internal () from /lib/libc.so.6
(gdb) step
Single stepping until exit from function _IO_vfscanf_internal,
which has no line number information.
0x0040f34a in vfscanf () from /lib/libc.so.6
(gdb) step
Single stepping until exit from function vfscanf,
which has no line number information.
0x0041414a in fscanf () from /lib/libc.so.6
(gdb) step
Single stepping until exit from function fscanf,
which has no line number information.
leseDatenIGS (input=0x9c20170, daten=0x9c202e8) at lese.cpp:232
/home/patrick/jamila/lese.cpp:232:5804:beg:0x8050fe0
(gdb) step
fscanf-rv: 6
(gdb) step
j nach fscanf: 0
(gdb)


Now, whom should I contact? glibc, gnu-c or gnu-c++?

-- 
CU,
   Patrick.

-- 
fedora-test-list mailing list
fedora-test-list@xxxxxxxxxx
To unsubscribe: 
https://www.redhat.com/mailman/listinfo/fedora-test-list

[Index of Archives]     [Fedora Desktop]     [Fedora SELinux]     [Photo Sharing]     [Yosemite Forum]     [KDE Users]