Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
home:jeff_mahoney:crash-python:devel
gdb
0012-py-infthread-add-dictionary-to-thread-obje...
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File 0012-py-infthread-add-dictionary-to-thread-object.patch of Package gdb
From abab439d9958aed8a1036bd5855832dbfab8b60b Mon Sep 17 00:00:00 2001 From: Jeff Mahoney <jeffm@suse.com> Date: Tue, 9 Feb 2016 01:01:47 -0500 Subject: [PATCH 12/17] py-infthread: add dictionary to thread object --- gdb/python/py-infthread.c | 3 ++- gdb/python/python-internal.h | 6 ++++++ 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/gdb/python/py-infthread.c b/gdb/python/py-infthread.c index 60af431b95c..c815d24d667 100644 --- a/gdb/python/py-infthread.c +++ b/gdb/python/py-infthread.c @@ -51,6 +51,7 @@ create_thread_object (struct thread_info *tp) thread_obj->thread = tp; thread_obj->inf_obj = (PyObject *) inf_obj.release (); + thread_obj->dict = NULL; return thread_obj; } @@ -449,7 +450,7 @@ PyTypeObject thread_object_type = 0, /* tp_dict */ 0, /* tp_descr_get */ 0, /* tp_descr_set */ - 0, /* tp_dictoffset */ + offsetof(thread_object, dict), /* tp_dictoffset */ 0, /* tp_init */ 0 /* tp_alloc */ }; diff --git a/gdb/python/python-internal.h b/gdb/python/python-internal.h index b3562887003..f15dc9386ce 100644 --- a/gdb/python/python-internal.h +++ b/gdb/python/python-internal.h @@ -383,6 +383,12 @@ struct thread_object /* The thread we represent. */ struct thread_info *thread; + /* + * Dictionary holding user-added attributes. + * This is the __dict__ attribute of the object. + */ + PyObject *dict; + /* The Inferior object to which this thread belongs. */ PyObject *inf_obj; }; -- 2.37.2
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor