Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
L
libzmq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
submodule
libzmq
Commits
631e12d4
Commit
631e12d4
authored
Jul 26, 2012
by
Ian Barber
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #404 from mimetnet/master
Correction for LIBZMQ-335
parents
9be0c7e4
a0eb0bb7
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
2 deletions
+10
-2
signaler.cpp
src/signaler.cpp
+10
-2
No files found.
src/signaler.cpp
View file @
631e12d4
...
@@ -233,6 +233,14 @@ int zmq::signaler_t::make_fdpair (fd_t *r_, fd_t *w_)
...
@@ -233,6 +233,14 @@ int zmq::signaler_t::make_fdpair (fd_t *r_, fd_t *w_)
return
0
;
return
0
;
#elif defined ZMQ_HAVE_WINDOWS
#elif defined ZMQ_HAVE_WINDOWS
SECURITY_DESCRIPTOR
sd
=
{
0
};
SECURITY_ATTRIBUTES
sa
=
{
0
};
InitializeSecurityDescriptor
(
&
sd
,
SECURITY_DESCRIPTOR_REVISION
);
SetSecurityDescriptorDacl
(
&
sd
,
TRUE
,
0
,
FALSE
);
sa
.
nLength
=
sizeof
(
SECURITY_ATTRIBUTES
);
sa
.
lpSecurityDescriptor
=
&
sd
;
// This function has to be in a system-wide critical section so that
// This function has to be in a system-wide critical section so that
// two instances of the library don't accidentally create signaler
// two instances of the library don't accidentally create signaler
...
@@ -241,9 +249,9 @@ int zmq::signaler_t::make_fdpair (fd_t *r_, fd_t *w_)
...
@@ -241,9 +249,9 @@ int zmq::signaler_t::make_fdpair (fd_t *r_, fd_t *w_)
// Note that if the event object already exists, the CreateEvent requests
// Note that if the event object already exists, the CreateEvent requests
// EVENT_ALL_ACCESS access right. If this fails, we try to open
// EVENT_ALL_ACCESS access right. If this fails, we try to open
// the event object asking for SYNCHRONIZE access only.
// the event object asking for SYNCHRONIZE access only.
HANDLE
sync
=
CreateEvent
(
NULL
,
FALSE
,
TRUE
,
TEXT
(
"
zmq-signaler-port-sync"
));
HANDLE
sync
=
CreateEvent
(
&
sa
,
FALSE
,
TRUE
,
TEXT
(
"Global
\\
zmq-signaler-port-sync"
));
if
(
sync
==
NULL
&&
GetLastError
()
==
ERROR_ACCESS_DENIED
)
if
(
sync
==
NULL
&&
GetLastError
()
==
ERROR_ACCESS_DENIED
)
sync
=
OpenEvent
(
SYNCHRONIZE
,
FALSE
,
TEXT
(
"
zmq-signaler-port-sync"
));
sync
=
OpenEvent
(
SYNCHRONIZE
|
EVENT_MODIFY_STATE
,
FALSE
,
TEXT
(
"Global
\\
zmq-signaler-port-sync"
));
win_assert
(
sync
!=
NULL
);
win_assert
(
sync
!=
NULL
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment