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]

Re: [python] [patch] PR python/13331


>>>>> "Paul" == Paul Koning <paulkoning@comcast.net> writes:

Paul> In this loop there is an example of what I mentioned: if
Paul> value_to_value_object returns NULL, exception status has been set, and
Paul> that should not be overwritten here.  On the other hand, there is
Paul> missing cleanup: any objects added to the tuple before the failing
Paul> call need to have a DECREF done on them.

Won't decref'ing the tuple do this for us?
If not then I think there are a lot of similar bugs elsewhere.
But .. how could it not?  That would be weird.

Paul> That should just be a cleanup and return NULL -- the
Paul> PyObject_GetAttrString has set the exception.

This (fnpy_call) is a "gdb-facing" function, so it has to use error.
It doesn't (and can't) follow the Python conventions.

Tom


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