This is the mail archive of the
gdb-patches@sources.redhat.com
mailing list for the GDB project.
[PATCH] Give message if dlopen(libthread_db) fails.
- From: Michael Snyder <msnyder at redhat dot com>
- To: gdb-patches at sources dot redhat dot com
- Date: Fri, 22 Nov 2002 17:35:44 -0800
- Subject: [PATCH] Give message if dlopen(libthread_db) fails.
- Organization: Red Hat, Inc.
Fairly obvious...
Index: thread-db.c
===================================================================
2002-11-22 Michael Snyder <msnyder@redhat.com>
* thread-db.c (thread_db_load): Tell the user what's going on
if dlopen fails on libthread_db.
RCS file: /cvs/src/src/gdb/thread-db.c,v
retrieving revision 1.24
diff -p -r1.24 thread-db.c
*** thread-db.c 12 Nov 2002 02:39:40 -0000 1.24
--- thread-db.c 23 Nov 2002 01:29:32 -0000
*************** thread_db_load (void)
*** 292,298 ****
handle = dlopen (LIBTHREAD_DB_SO, RTLD_NOW);
if (handle == NULL)
! return 0;
/* Initialize pointers to the dynamic library functions we will use.
Essential functions first. */
--- 292,304 ----
handle = dlopen (LIBTHREAD_DB_SO, RTLD_NOW);
if (handle == NULL)
! {
! fprintf_filtered (gdb_stderr, "\n\ndlopen failed on '%s' - %s\n",
! LIBTHREAD_DB_SO, dlerror ());
! fprintf_filtered (gdb_stderr,
! "GDB will not be able to debug pthreads.\n\n");
! return 0;
! }
/* Initialize pointers to the dynamic library functions we will use.
Essential functions first. */