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
2e55bc58
Commit
2e55bc58
authored
8 years ago
by
Luca Boccassi
Committed by
GitHub
8 years ago
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #2125 from GreatFruitOmsk/master
Fix fd_entry may reference invalid object.
parents
22dac194
06614a39
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
11 deletions
+9
-11
select.cpp
src/select.cpp
+9
-11
No files found.
src/select.cpp
View file @
2e55bc58
...
...
@@ -353,29 +353,27 @@ void zmq::select_t::loop ()
// Size is cached to avoid iteration through just added descriptors.
for
(
fd_entries_t
::
size_type
i
=
0
,
size
=
fd_entries
.
size
();
i
<
size
&&
rc
>
0
;
++
i
)
{
fd_entry_t
&
fd_entry
=
fd_entries
[
i
];
if
(
fd_entry
.
fd
==
retired_fd
)
if
(
fd_entries
[
i
].
fd
==
retired_fd
)
continue
;
if
(
FD_ISSET
(
fd_entr
y
.
fd
,
&
local_fds_set
.
read
))
{
fd_entr
y
.
events
->
in_event
();
if
(
FD_ISSET
(
fd_entr
ies
[
i
]
.
fd
,
&
local_fds_set
.
read
))
{
fd_entr
ies
[
i
]
.
events
->
in_event
();
--
rc
;
}
if
(
fd_entr
y
.
fd
==
retired_fd
||
rc
==
0
)
if
(
fd_entr
ies
[
i
]
.
fd
==
retired_fd
||
rc
==
0
)
continue
;
if
(
FD_ISSET
(
fd_entr
y
.
fd
,
&
local_fds_set
.
write
))
{
fd_entr
y
.
events
->
out_event
();
if
(
FD_ISSET
(
fd_entr
ies
[
i
]
.
fd
,
&
local_fds_set
.
write
))
{
fd_entr
ies
[
i
]
.
events
->
out_event
();
--
rc
;
}
if
(
fd_entr
y
.
fd
==
retired_fd
||
rc
==
0
)
if
(
fd_entr
ies
[
i
]
.
fd
==
retired_fd
||
rc
==
0
)
continue
;
if
(
FD_ISSET
(
fd_entr
y
.
fd
,
&
local_fds_set
.
error
))
{
fd_entr
y
.
events
->
in_event
();
if
(
FD_ISSET
(
fd_entr
ies
[
i
]
.
fd
,
&
local_fds_set
.
error
))
{
fd_entr
ies
[
i
]
.
events
->
in_event
();
--
rc
;
}
}
...
...
This diff is collapsed.
Click to expand it.
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