This is the mail archive of the mailing list for the Archer 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]

ping: Re: [python] [patch] Fix crash on remote targets [Re:[python] python-inferior add_inferior_object tries to access thread infobefore it exists with remote target (VMware remote stub)]

Hi Tom,

ping, this bug costs daily many watthours of testbox. :-)




tried first to get working get_current_arch at the add_inferior_object time
but found it is probably right it does not work at that time.

gdb.server/server-run.exp currently crashes with:
thread.c:581: internal-error: is_thread_state: Assertion `tp' failed.

No regressions on {x86_64,x86_64-m32,i686}-fedora11-linux-gnu.


2009-09-17  Jan Kratochvil  <>

	* python/py-inferior.c (add_inferior_object): Call ensure_python_env
	just with target_gdbarch, new comment.

--- a/gdb/python/py-inferior.c
+++ b/gdb/python/py-inferior.c
@@ -104,7 +104,10 @@ add_inferior_object (int pid)
-  cleanup = ensure_python_env (get_current_arch (), current_language);
+  /* While creating new inferior no inferior thread is available.  Therefore
+     get_current_arch has no valid current frame (and it would crash).  */
+  cleanup = ensure_python_env (target_gdbarch, current_language);
   inf_obj = PyObject_New (inferior_object, &inferior_object_type);
   if (!inf_obj)

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