Commit Graph

9 Commits

Author SHA1 Message Date
Alex Villacís Lasso
78953656ef Eagerly flush as much data as possible from write queue
This commit implements a policy of writing as many queued buffers as the
writable socket allows, until non-writable, or the write queue is empty.
This has two objectives: 1) any allocated buffers for data copies will
be freed sooner, 2) the write output will be more responsive, fixing at
least one known delay in WiFi scanlist output in YUBOX Now.
2021-08-03 18:16:32 -05:00
Andrii
7168825854 Fixes #2 (#3)
* fixed reorder "error-as-warning"

* reverted code reformatting
2021-03-14 11:26:03 -05:00
Alex Villacís Lasso
0ad4a10c88 Flush some writable data on AsyncClient::send() 2021-02-27 20:55:02 -05:00
Alex Villacís Lasso
ddd0bc9290 Clear all callbacks on close or error 2020-12-23 16:41:29 -05:00
Alex Villacís Lasso
2bb8788ec1 Protect write buffer queue with a per-client mutex
This prevents a race condicion of the ::add() method modifying the queue
and being preempted by the high-priority asyncTcpSock task that in turn
flushes the same queue to the socket, therefore modifying the queue.
2020-12-21 18:21:27 -05:00
Alex Villacís Lasso
9ee3bda5ae Add abort() support if enabled in LWIP 2020-12-21 14:04:00 -05:00
Alex Villacís Lasso
de2a0da915 Implement write() and free() methods
Also comment out one prototype not yet implemented.
2020-12-21 13:48:24 -05:00
Alex Villacís Lasso
7a70bda9ce Place code under the same license as original AsyncTCP 2020-12-21 13:16:21 -05:00
Alex Villacís Lasso
5f24debb27 Initial commit 2020-12-19 17:28:53 -05:00