diff options
author | Clombrong <cromblong@egregore.fun> | 2025-06-28 09:49:00 +0200 |
---|---|---|
committer | Clombrong <cromblong@egregore.fun> | 2025-06-28 16:44:54 +0200 |
commit | 52df0ce483eb7d7e76a67ad5e70bc586de2fd6e8 (patch) | |
tree | 1004e4d0cb587822e9a2f7597e675dd167800f98 /portal/tcp/portal.ml | |
parent | 3250b3b0da536e4fbfc1290886e98a02a2f51c15 (diff) |
fix(portal_tcp): resolve the comment incident
Diffstat (limited to 'portal/tcp/portal.ml')
-rw-r--r-- | portal/tcp/portal.ml | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/portal/tcp/portal.ml b/portal/tcp/portal.ml index fc19fc0..9241312 100644 --- a/portal/tcp/portal.ml +++ b/portal/tcp/portal.ml @@ -133,7 +133,11 @@ let socket_to_stream (sock : socket) = if len > 0 then begin send_pos := 0; - flush_socket len + if (Lwt_bytes.proxy send_buffer (len-7) len |> Lwt_bytes.to_string) = "<!---->" + then if (len - 7) > 0 + then flush_socket (len - 7) + else Lwt.return_unit + else flush_socket len end else Lwt.return_unit in |