The following code
open Lwt
open Printf
module Client = Cohttp_lwt_unix.Client
let get url =
Client.get url >>= fun (_, b) ->
Cohttp_lwt_body.to_string b >>= fun data ->
Lwt_io.printf "%s\n%!" data
let () =
Lwt_main.run(get (Uri.of_string "http://blog.camlcity.org/blog/rss"))
fails to download the complete body of the URL.
The following code
fails to download the complete body of the URL.