From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 12703 invoked by alias); 3 Feb 2007 14:59:08 -0000 Received: (qmail 12694 invoked by uid 22791); 3 Feb 2007 14:59:07 -0000 X-Spam-Check-By: sourceware.org Received: from ug-out-1314.google.com (HELO ug-out-1314.google.com) (66.249.92.169) by sourceware.org (qpsmtpd/0.31) with ESMTP; Sat, 03 Feb 2007 14:59:01 +0000 Received: by ug-out-1314.google.com with SMTP id 75so1009300ugb for ; Sat, 03 Feb 2007 06:58:59 -0800 (PST) Received: by 10.67.21.11 with SMTP id y11mr9415ugi.1170514739070; Sat, 03 Feb 2007 06:58:59 -0800 (PST) Received: from ?10.0.0.1? ( [85.207.125.235]) by mx.google.com with ESMTP id 34sm5782556uga.2007.02.03.06.58.57; Sat, 03 Feb 2007 06:58:58 -0800 (PST) Message-ID: <45C4A331.1080801@gmail.com> Date: Sat, 03 Feb 2007 14:59:00 -0000 From: Simon Toth User-Agent: Thunderbird 2.0b2 (Windows/20070116) MIME-Version: 1.0 To: gdb@sourceware.org Subject: Selft tracing utility Content-Type: text/plain; charset=ISO-8859-2; format=flowed Content-Transfer-Encoding: 7bit X-IsSubscribed: yes Mailing-List: contact gdb-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sourceware.org X-SW-Source: 2007-02/txt/msg00021.txt.bz2 Hi, I'm currently extending the debug support for my programs and trying to find something that will dump the current call-stack. GDB can do this, the problem is can a running process dump itself? My idea is something like: getpid() dump the call-stack by running gdb ataching it to the process by pid abort() Is there a posibility to run gdb thru some API? Thx for any ideas Bc. Simon Toth