[PATCH v2 6/6] Use correct inferior in Inferior.read_memory et al

Pedro Alves pedro@palves.net
Fri Jul 14 16:56:07 GMT 2023


On 2023-07-14 17:48, Pedro Alves wrote:
> On 2023-07-11 17:14, Tom Tromey via Gdb-patches wrote:
>> A user noticed that Inferior.read_memory and a few other Python APIs
>> will always use the currently selected inferior, not the one passed to
>> the call.
>>
>> This patch fixes the bug by arranging to switch to the inferior.  I
>> found this same issue in several APIs, so this fixes them all.
>>
>> I also added a few missing calls to INFPY_REQUIRE_VALID to these
>> methods.
>>
> 
> Approved-By: Pedro Alves <pedro@palves.net>
> 

I wrote a bunch of text that I ended up deleting ( don't ask :-) ) and then forgot
that I also had some comments on the testcase...  :-P  I'll reply to v3, which I only
noticed now was out already.


More information about the Gdb-patches mailing list