gdb-requ...@gnu.org wrote:
Message: 1
Date: Tue, 27 Jan 2009 21:15:43 -0800 (PST)
From: UltrosMaximus <rob.rus...@gmail.com>
Subject: Break point on shared library function not working...?
To: Gdb@gnu.org
Message-ID: <21700134.p...@talk.nabble.com>
Content-Type: text/plain; charset=us-ascii
Hey, so I'm just writing a small little c program here and trying to get the
break points working but I can't seem to get it to break on a shared
library.
here's my program:
#include <stdio.h>
#include <string.h>
int main() {
char str_a[20]'
strcpy(str_a, "hello");
printf(str_a);
}
(snip)
Don't think breaking on such a call should work, anyway. How would gdb
know which (of possibly many strcpy calls) to break on. All? Then what
- gdb stepping through it would be useless (no debug info). Just break
on char_array2.c:6 . Want to trace all calls to strcpy? Add your own
and break on its first line (compiler will howl but do what you said).
And by the way, if you do, with "break strcpy", my gdb will in fact
break on the FIRST call only !