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
bd3c897e
Commit
bd3c897e
authored
Jul 10, 2013
by
antirez
Browse files
anet.c: save some vertical space.
parent
d83dca4c
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/anet.c
View file @
bd3c897e
...
...
@@ -237,18 +237,11 @@ static int anetTcpGenericConnect(char *err, char *addr, int port, int flags)
continue
;
/* if we set err then goto cleanup, otherwise next */
if
(
anetSetReuseAddr
(
err
,
s
)
==
ANET_ERR
)
{
if
(
anetSetReuseAddr
(
err
,
s
)
==
ANET_ERR
)
goto
error
;
if
(
flags
&
ANET_CONNECT_NONBLOCK
&&
anetNonBlock
(
err
,
s
)
!=
ANET_OK
)
goto
error
;
}
if
(
flags
&
ANET_CONNECT_NONBLOCK
)
{
if
(
anetNonBlock
(
err
,
s
)
!=
ANET_OK
)
goto
error
;
}
if
(
connect
(
s
,
p
->
ai_addr
,
p
->
ai_addrlen
)
==
-
1
)
{
if
(
errno
==
EINPROGRESS
&&
flags
&
ANET_CONNECT_NONBLOCK
)
goto
end
;
if
(
errno
==
EINPROGRESS
&&
flags
&
ANET_CONNECT_NONBLOCK
)
goto
end
;
close
(
s
);
continue
;
}
...
...
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