Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
ruanhaishen
redis
Commits
cf887795
Unverified
Commit
cf887795
authored
Nov 26, 2020
by
kukey
Committed by
GitHub
Nov 25, 2020
Browse files
Merge two aeDeleteFileEvent refs into one (#7521)
Merge two aeDeleteFileEvent refs into one
parent
79a7c171
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/connection.c
View file @
cf887795
...
@@ -147,8 +147,7 @@ void *connGetPrivateData(connection *conn) {
...
@@ -147,8 +147,7 @@ void *connGetPrivateData(connection *conn) {
/* Close the connection and free resources. */
/* Close the connection and free resources. */
static
void
connSocketClose
(
connection
*
conn
)
{
static
void
connSocketClose
(
connection
*
conn
)
{
if
(
conn
->
fd
!=
-
1
)
{
if
(
conn
->
fd
!=
-
1
)
{
aeDeleteFileEvent
(
server
.
el
,
conn
->
fd
,
AE_READABLE
);
aeDeleteFileEvent
(
server
.
el
,
conn
->
fd
,
AE_READABLE
|
AE_WRITABLE
);
aeDeleteFileEvent
(
server
.
el
,
conn
->
fd
,
AE_WRITABLE
);
close
(
conn
->
fd
);
close
(
conn
->
fd
);
conn
->
fd
=
-
1
;
conn
->
fd
=
-
1
;
}
}
...
...
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