Fix ezcurl 0.3 compatibility issue

The ezcurl library changed its client type from Curl.t to Ezcurl_core.t
(an unboxed record type) in version 0.3. Updated both sync and lwt
implementations to use the correct type and module functions.
This commit is contained in:
Simon Cruanes 2026-02-08 07:03:43 +00:00
parent 1ebd474423
commit 21e799ae61
2 changed files with 4 additions and 4 deletions

View file

@ -23,11 +23,11 @@ module Httpc : Generic_http_consumer.HTTPC with module IO = IO = struct
module IO = IO
open Lwt.Syntax
type t = Curl.t
type t = Ezcurl_core.t
let create () : t = Ezcurl_core.make ()
let create () : t = Ezcurl_lwt.make ()
let cleanup self = Ezcurl_core.delete self
let cleanup self = Ezcurl_lwt.delete self
(** send the content to the remote endpoint/path *)
let send (self : t) ~url ~decode (bod : string) : ('a, error) result Lwt.t =

View file

@ -24,7 +24,7 @@ end
module Httpc : OTELC.Generic_http_consumer.HTTPC with module IO = IO = struct
module IO = IO
type t = Curl.t
type t = Ezcurl_core.t
let create () = Ezcurl.make ()