Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Replace establish_server by establish_server_safe #260

Closed
aantron opened this issue Jun 25, 2016 · 0 comments
Closed

Replace establish_server by establish_server_safe #260

aantron opened this issue Jun 25, 2016 · 0 comments
Labels

Comments

@aantron
Copy link
Collaborator

aantron commented Jun 25, 2016

Lwt_io.establish_server_safe closes channels automatically and was introduced in #258. I looked at users of the original establish_server in OPAM (as of today), and none would be negatively affected by closing channels automatically. Hopefully, this also holds true of most or all non-OPAM users.

The signatures are incompatible, so code would have to be adjusted:

val establish_server_safe :
  ?fd : Lwt_unix.file_descr ->
  ?buffer_size : int ->
  ?backlog : int ->
  Unix.sockaddr -> (input_channel * output_channel -> unit Lwt.t) -> server
val establish_server :
  ?fd : Lwt_unix.file_descr ->
  ?buffer_size : int ->
  ?backlog : int ->
  Unix.sockaddr -> (input_channel * output_channel -> unit) -> server
aantron added a commit that referenced this issue Oct 20, 2016
This function will replace Lwt_io.establish_server. It's better if users
don't refer to it by its current name. The current
Lwt_io.establish_server will go through some deprecation process once
4.01 support is dropped.

See #260.

[skip ci]
aantron added a commit that referenced this issue Apr 8, 2017
aantron added a commit that referenced this issue Apr 9, 2017
aantron added a commit that referenced this issue Apr 10, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant