pyOCD
pyOCD copied to clipboard
Fixed bug in dap.py - local call of function overwritten the input pa…
Hello, I found bad hadling of now parameter in dap.py read_ap_multiple method.
Hope that this will be useful.
Hi @Gargy007 , did you see an issue caused by the original code? It was intentionally written that way so that the call to self.probe_read_ap_multiple()
always returns a result callback, which then is always invoked in read_ap_multiple_cb()
. The point is to a) simplify the number of code paths, b) ensure that the returned read callback is wrapped in the exception handler in read_ap_multiple_cb()
when it is executed (so _handle_error()
is called on an exception).
However, I could have certainly made a mistake! In any case, I really appreciate you contributing. 😄