以下
let new_socket () = Lwt_unix.socket Unix.PF_INET Unix.SOCK_STREAM 0 in
let socket_address = Network.make_address "127.0.0.1" 7777 in
let listening_socket = new_socket () in
Lwt_unix.setsockopt listening_socket Unix.SO_REUSEADDR true;
Lwt_unix.bind listening_socket socket_address;
このエラーが発生します。
エラー: 正当性:2:remote_client:0:set
Unix.Unix_error(Unix.EADDRINUSE, "bind", "")
Raised at file "src/core/lwt.ml", line 782, characters 22-23
Called from file "src/unix/lwt_main.ml", line 34, characters 8-18
Called from file "src/oUnit.ml", line 597, characters 6-10`
最後の行はバインドを許可できません。なぜ、これを渡す方法を考えていますか?