---

**[tickets:#414] Semihosting message redirection TCP server gets the input data 
flushed before it can be used**

**Status:** new
**Milestone:** 0.11.0
**Labels:** semihosting 
**Created:** Wed Sep 06, 2023 03:38 PM UTC by Marek Vrbka
**Last Updated:** Wed Sep 06, 2023 03:38 PM UTC
**Owner:** nobody


Consider that the debugged target is repeatedly making READC semihosting call 
after `arm semihosting_redirect tcp 7777 all` has been run. Target stops on the 
semihosting call while OpenOCD is waiting for data. We send for 10 bytes at 
once to the TCP socket.

Expected behavior: Data is buffered until target makes 10 READC semihosting 
calls to read all of it.

Actual behavior: Target gets one byte, rest of the data is flushed by 
`semihosting_service_input_handler()` before it can be used.

I suspect the regular READ semihosting call has the same issue.


---

Sent from sourceforge.net because openocd-devel@lists.sourceforge.net is 
subscribed to https://sourceforge.net/p/openocd/tickets/

To unsubscribe from further messages, a project admin can change settings at 
https://sourceforge.net/p/openocd/admin/tickets/options.  Or, if this is a 
mailing list, you can unsubscribe from the mailing list.


Reply via email to