Hi. I'm using Mongoose 5.4 and I noticed that when called from a user defined handler, the following function produces its output with a 30 seconds delay:
mg_write (conn, "HTTP/1.1 200 OK\r\nContent-Type: text/plain\r\n\r\n<some_data>", strlen ("HTTP/1.1 200 OK\r\nContent-Type: text/plain\r\n\r\n<some_data>"));
while the following combination, producing the same output, does its job immediately:
mg_send_header (conn, "Content-Type", "text/plain");
mg_printf_data (conn, "%s", "<some_data>");
What is the cause of the huge delay when using the mg_write function?
Thanks.