Sometimes mbedtls returns WANT_READ/WANT_WRITE errors (the case I encountered while working on https://github.com/HaxeFoundation/hashlink/pull/681 seems to be due to session tickets).
These should be interpreted as "retry when more data is known to be available", but there is no good way to express that in the current api when the socket is blocking other than returning zero.
…e blocking.
Sometimes mbedtls returns WANT_READ/WANT_WRITE errors (the case I encountered while working on https://github.com/HaxeFoundation/hashlink/pull/681 seems to be due to session tickets). These should be interpreted as "retry when more data is known to be available", but there is no good way to express that in the current api when the socket is blocking other than returning zero.
Together with https://github.com/HaxeFoundation/hashlink/pull/681 this should be enough to get rid of the HL+macOS failures in https://github.com/HaxeFoundation/haxe/pull/11638.