diff options
author | Mohit Agrawal <moagrawa@redhat.com> | 2017-05-13 10:06:50 +0530 |
---|---|---|
committer | Jeff Darcy <jeff@pl.atyp.us> | 2017-05-15 12:15:44 +0000 |
commit | 710cd0ae8f2dd0495ab483df050720b5c862688d (patch) | |
tree | 37d9ddb2bce13c2551c84b33fc8d116bed508bee /rpc/rpc-transport/socket/src | |
parent | cb6837d03658c1005475d4040fa95504b3fd84d0 (diff) |
socket: Avoid flooding of error message in case of SSL
Problem: socket poller is throwing Input/Output messages during volume operation
Solution: Update the code in socket_connect function before call
socket_spwan.
BUG: 1450559
Change-Id: I5f275fe7a4b730b16d7b0a0407e76288b07ceaef
Signed-off-by: Mohit Agrawal <moagrawa@redhat.com>
Reviewed-on: https://review.gluster.org/17280
NetBSD-regression: NetBSD Build System <jenkins@build.gluster.org>
Smoke: Gluster Build System <jenkins@build.gluster.org>
Reviewed-by: Zhou Zhengping <johnzzpcrystal@gmail.com>
CentOS-regression: Gluster Build System <jenkins@build.gluster.org>
Reviewed-by: Jeff Darcy <jeff@pl.atyp.us>
Diffstat (limited to 'rpc/rpc-transport/socket/src')
-rw-r--r-- | rpc/rpc-transport/socket/src/socket.c | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/rpc/rpc-transport/socket/src/socket.c b/rpc/rpc-transport/socket/src/socket.c index e14152c5822..d59dd6cf49f 100644 --- a/rpc/rpc-transport/socket/src/socket.c +++ b/rpc/rpc-transport/socket/src/socket.c @@ -3350,7 +3350,16 @@ handler: rpc_transport_ref (this); refd = _gf_true; - if (priv->own_thread && !(priv->connect_failed)) { + if (priv->own_thread) { + if (priv->connect_failed) { + gf_msg_debug (this->name, 0, + "socket connect is failed so close it"); + sys_close (priv->sock); + priv->sock = -1; + ret = -1; + goto unlock; + } + if (pipe(priv->pipe) < 0) { gf_log(this->name,GF_LOG_ERROR, "could not create pipe"); |