This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

meaningful error message in gdbserver


Hi,

I had a long day fighting with remote debugging, until I found out that my
libpthread and libthread_db versions didn't match. So I created the patch
below that makes gdbserver more verbose when failing, maybe it can save
some time for somebody in the future.

br

Szo

==========================================================================

diff -ruw gdb-6.3.50.20050831-orig/gdb/gdbserver/thread-db.c gdb-6.3.50.20050831/gdb/gdbserver/thread-db.c
--- gdb-6.3.50.20050831-orig/gdb/gdbserver/thread-db.c	2005-08-31 18:12:56.000000000 +0200
+++ gdb-6.3.50.20050831/gdb/gdbserver/thread-db.c	2005-08-31 18:27:18.000000000 +0200
@@ -351,6 +351,10 @@
       /* No thread library was detected.  */
       return 0;

+    case TD_VERSION:
+      warning ("error initializing thread_db library:\nVersion of libpthread and libthread_db mismatch.");
+      return 0;
+
     case TD_OK:
       /* The thread library was detected.  */


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]