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

Problem: zsys_udp_new reference internal ZMQ macros #1901

Merged
merged 2 commits into from
Apr 20, 2018

Conversation

vyskocilm
Copy link
Contributor

Solution: use external ones
fixes: #1899 #1900

src/zsys.c Outdated
// On Windows, preventing sockets to be inherited by child processes.
#if defined ZMQ_HAVE_WINDOWS && defined HANDLE_FLAG_INHERIT
#if defined (__WINDOWS__) && defined (HANDLE_FLAG_INHERIT)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There's CZMQ_HAVE_WINDOWS please use that one

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed in latest commit

Solution: use suggested macro for conditional compilation
@sappo sappo merged commit 99f1c03 into zeromq:master Apr 20, 2018
@@ -981,7 +981,7 @@ zsys_udp_new (bool routable)
assert (!routable);
SOCKET udpsock;
int type = SOCK_DGRAM;
#if defined ZMQ_HAVE_SOCK_CLOEXEC
#if defined (SOCK_CLOEXEC)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@vyskocilm this will breaks some platforms - it needs to be done in cmake and autoconf like in libzmq

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

Successfully merging this pull request may close these issues.

Problem: UDP socket descriptor leak with exec'd processes
3 participants