On Sat, Nov 4, 2017 at 10:13 PM, Tomas Vanek <[email protected]>
wrote:

> On 04.11.2017 21:53, Andreas Fritiofson wrote:
>
>
> Why isn't the corresponding target always passed to the Tcl event handler
> (in target_handle_event)? Seems like a handler would always need that if
> it's doing more than echoing something.
>
> Odd... How does the current handlers work if there's more than one target?
> I.e. those that simply do mww etc. in the handler. Is the "current target"
> somehow always pointing to the relevant target when the handler is
> executing? If yes, well you could use that, if not then all stock handlers
> are broken.
>
> No, my tests show the current target is unchanged during event handling.
> Lot of target handlers work with current target regardless of the target
> they was invoked from.
>
>
>
So that means they are broken? How would fixing it using my suggestion
above sound? Passing the target name to the handlers, always, and rewriting
all handlers to use $t mww and so on.

/Andreas
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
OpenOCD-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/openocd-devel

Reply via email to