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

Expose zmq_setsockopt publicly #342

Open
grahamjameson opened this issue May 13, 2022 · 4 comments
Open

Expose zmq_setsockopt publicly #342

grahamjameson opened this issue May 13, 2022 · 4 comments

Comments

@grahamjameson
Copy link

A diff for such a change might look like:

**diff --git a/src/lib.rs b/src/lib.rs
index c8c2b91..60468c8 100644
--- a/src/lib.rs
+++ b/src/lib.rs
@@ -31,7 +31,7 @@ macro_rules! zmq_try {
 }
 
 mod message;
-mod sockopt;
+pub mod sockopt;
 
 use crate::message::msg_ptr;
 pub use crate::message::Message;**

I would be happy to open a PR given feedback from maintainers about how they would like the change to be made so that it is most likely to be merged.

@andrewdavidmackenzie
Copy link

+1

I want to set SO_REUSEADDR on a socket, and I cannot find a way to do so (from rust) currently, and I understand this is the method I would require. I see some macros in the code but cannot find docs on them...

@grahamjameson
Copy link
Author

@andrewdavidmackenzie hopefully you already figured this out, but you can work around this by separately using the zmq_sys crate that exists within this one.

@andrewdavidmackenzie
Copy link

Was wondering if you thought this would get exposed in zmq (rust), or zmq_sys will be the only way and no point in waiting?

@grahamjameson
Copy link
Author

@andrewdavidmackenzie It seems this project is no longer maintained. My personal recommendation would be to use zmq_sys, as that will be less work than forking.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants