From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 6938 invoked by alias); 15 Apr 2005 10:02:53 -0000 Mailing-List: contact gdb-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sources.redhat.com Received: (qmail 6821 invoked from network); 15 Apr 2005 10:02:44 -0000 Received: from unknown (HELO ciao.gmane.org) (80.91.229.2) by sourceware.org with SMTP; 15 Apr 2005 10:02:44 -0000 Received: from list by ciao.gmane.org with local (Exim 4.43) id 1DMNbJ-0007T9-PE for gdb@sources.redhat.com; Fri, 15 Apr 2005 11:59:01 +0200 Received: from 130.225.245.182 ([130.225.245.182]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Fri, 15 Apr 2005 11:59:01 +0200 Received: from fedevaps by 130.225.245.182 with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Fri, 15 Apr 2005 11:59:01 +0200 To: gdb@sources.redhat.com From: JS Subject: Re: Still cannot print variable Date: Fri, 15 Apr 2005 10:02:00 -0000 Message-ID: References: <238614216.20050415132437@ispras.ru> Reply-To: fedevaps@yahoo.dk Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7Bit X-Complaints-To: usenet@sea.gmane.org X-Gmane-NNTP-Posting-Host: 130.225.245.182 User-Agent: KNode/0.7.7 X-SW-Source: 2005-04/txt/msg00092.txt.bz2 Konstantin Karganov wrote: > Hello JS, > >> I run "gdb test" followed by "print d" and then I get this error: > >> No symbol "d" in current context. > >> Why is it not possible to see the contents of "d" when debugging? > > Because you are not yet debugging! > As described above, you started the debugger but not started the > program being debugged. > Try this: > gdb test > break main // to stop your program run > run > print d > Ok now it work but when I write "print d" I get: $1 = 134513410 But I declared d to be 119. I have tried the different print arguments: x d u o etc. but nothig seems to print 119.