-
Notifications
You must be signed in to change notification settings - Fork 4
Open
Description
The following finalize never executes unless the handler is blocked awaiting an operation in the stream finish.
#include "uv/tcp.ceu"
#define LOCALHOST "0.0.0.0"
#define PORT 8888
#define BACKLOG 128
data UV_TCP_Server_Data;
code/await UV_TCP_Server_Handler (var& UV_Stream client,
var& UV_TCP_Server_Data shared) -> int
do
do finalize with
_printf ("finalize\n");
end
await FOREVER; //If we change this to awai UV_Stream_Read_N (&client, _) it works.
end
#include "uv/tcp-server.ceu"
par do
await UV_TCP_Server (LOCALHOST, PORT, BACKLOG, _, _);
with
var&? UV_TCP_Connect client = spawn UV_TCP_Connect (LOCALHOST, PORT, _);
await 1s;
_printf ("close connection\n");
end
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels