Article View: gnu.gdb.bug
Article #213gdb and printing values of function calls
From: Eric Van Tassell
Date: Wed, 26 Jul 1989 14:37
Date: Wed, 26 Jul 1989 14:37
35 lines
1326 bytes
1326 bytes
Ok folks , what am I doing wrong here with GDB 3.2 on Sun 3/60 with SunOS 3.5?
(gdb) p dp(format)
$1 = -2147483648
(gdb) p dp(dpy)
$2 = -2147483648
(gdb) p sin(0)
$3 = -2147483648
(gdb) p cos(0.0)
$4 = -2147483648
(gdb) p fopen("booger","r")
$5 = -2147483648
(gdb)
- dp is my own Debug Print routine
- format and dpy are two very different variables
(a symbol and XDisplay)
- sin, cos, fopen all produce the same result
- under dbx p sin(0) => 0 (which is what we expect)
- under dbx p dp(format) => "XY-PIXMAP"
? Why does every attempt result in the same value being returned?
Does anybody have a clue as to why I cant seem to print the value resulting
from calling a function.re? Failing a fix could someone give
me a few ideas. TIA!
eric
--
Eric Van Tassell(dlcdev!eric@eddie.mit.edu)
Progress Software Corp.
22B Cotton Rd.
Nashua, NH 03063 {603-882-2488}
Technical Details
Message-ID:
<12277@eddie.MIT.EDU>Path:
arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!rutgers!mit-eddie!ericShow Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!rutgers!mit-eddie!eric From: eric@eddie.MIT.EDU (Eric Van Tassell) Newsgroups: gnu.gdb.bug Subject: gdb and printing values of function calls Keywords: gdb,printing,function calls Message-ID: <12277@eddie.MIT.EDU> Date: 26 Jul 89 14:37:10 GMT Organization: MIT EE/CS Computer Facility, Cambridge, MA Lines: 35