This is the mail archive of the archer@sourceware.org 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]

Re: [[inferior events] partial cleanup for copy_py_list


On 12/14/2010 04:41 PM, Tom Tromey wrote:
This fixes some issues in copy_py_list, but not all.

The patch changes it to check PyList_Append.

I think it should probably use an iterator to go through the list.
Otherwise it is susceptible to a bug where another thread changes the
list while we are iterating over it.


Hmm I did not know we had the option of using a safe iterator. If we do then that eliminates the need for copy_py_list in the first place; copy_py_list is used to make the call back of listeners safe against one listener editing the list during the iteration by removing an element.


Still, ok to push in this form?


Yes. And thanks for the cleanups.


Sami


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