Kyle Robbertze pushed to branch master at Debian OCaml Maintainers / ocaml-cry
Commits:
-
aac8a37f
by Kyle Robbertze at 2024-04-06T09:29:27+01:00
-
a15577a4
by Kyle Robbertze at 2024-04-06T09:29:28+01:00
-
17a0aeee
by Kyle Robbertze at 2024-04-06T09:31:50+01:00
6 changed files:
Changes:
| 1 | +1.0.3 (2024-03-18)
|
|
| 2 | +=====
|
|
| 3 | +* Raise a proper error when non-blocking connection
|
|
| 4 | + fails.
|
|
| 5 | +* Fix poll segfault.
|
|
| 6 | + |
|
| 1 | 7 | 1.0.2 (2024-01-08)
|
| 2 | 8 | ======
|
| 3 | 9 | * Use `poll` for select when available.
|
| 1 | 1 | # This file is generated by dune, edit dune-project instead
|
| 2 | 2 | opam-version: "2.0"
|
| 3 | -version: "1.0.2"
|
|
| 3 | +version: "1.0.3"
|
|
| 4 | 4 | synopsis: "OCaml client for the various icecast & shoutcast source protocols"
|
| 5 | 5 | description:
|
| 6 | 6 | "The cry library is an implementation of the various icecast & shoutcast protocols to connect to streaming servers such as icecast"
|
| 1 | +ocaml-cry (1.0.3-1) unstable; urgency=medium
|
|
| 2 | + |
|
| 3 | + * New upstream version 1.0.3
|
|
| 4 | + |
|
| 5 | + -- Kyle Robbertze <paddatrapper@debian.org> Sat, 06 Apr 2024 09:29:34 +0100
|
|
| 6 | + |
|
| 1 | 7 | ocaml-cry (1.0.2-2) unstable; urgency=medium
|
| 2 | 8 | |
| 3 | 9 | * Team upload
|
| 1 | 1 | (lang dune 2.8)
|
| 2 | -(version 1.0.2)
|
|
| 2 | +(version 1.0.3)
|
|
| 3 | 3 | (name cry)
|
| 4 | 4 | (source (github savonet/ocaml-cry))
|
| 5 | 5 | (license GPL-2.0-only)
|
| ... | ... | @@ -163,14 +163,15 @@ let connect_sockaddr ?bind_address ?timeout sockaddr = |
| 163 | 163 | Printexc.raise_with_backtrace exn bt);
|
| 164 | 164 | let do_timeout = timeout <> None in
|
| 165 | 165 | let check_timeout () =
|
| 166 | - match timeout with
|
|
| 167 | - | Some timeout ->
|
|
| 168 | - (* Block in a select call for [timeout] seconds. *)
|
|
| 169 | - let _, w, _ = select [] [socket] [] timeout in
|
|
| 170 | - if w = [] then raise Timeout;
|
|
| 166 | + let timeout = Option.get timeout in
|
|
| 167 | + (* Block in a select call for [timeout] seconds. *)
|
|
| 168 | + let _, w, _ = select [] [socket] [] timeout in
|
|
| 169 | + if w = [] then raise Timeout;
|
|
| 170 | + match Unix.getsockopt_error socket with
|
|
| 171 | + | Some err -> raise (Unix.Unix_error (err, "connect", ""))
|
|
| 172 | + | None ->
|
|
| 171 | 173 | Unix.clear_nonblock socket;
|
| 172 | 174 | socket
|
| 173 | - | None -> assert false
|
|
| 174 | 175 | in
|
| 175 | 176 | let finish () =
|
| 176 | 177 | try
|
| ... | ... | @@ -109,7 +109,7 @@ CAMLprim value caml_cry_poll(value _read, value _write, value _err, |
| 109 | 109 | nwrite++;
|
| 110 | 110 | }
|
| 111 | 111 | if (fds[n].revents & POLLERR) {
|
| 112 | - Store_field(_pread, nerr, Val_fd(fds[n].fd));
|
|
| 112 | + Store_field(_perr, nerr, Val_fd(fds[n].fd));
|
|
| 113 | 113 | nerr++;
|
| 114 | 114 | }
|
| 115 | 115 | }
|