diff options
| author | Donald Sharp <sharpd@cumulusnetworks.com> | 2019-10-09 13:50:42 -0400 |
|---|---|---|
| committer | Donald Sharp <sharpd@cumulusnetworks.com> | 2020-03-06 16:03:52 -0500 |
| commit | fa696b37276b7c396e55aba1a55b0b7441af14e9 (patch) | |
| tree | 656366b48d3322d4ed1ef2f37f10368563d6f666 | |
| parent | 22c35834ea43ebec121c0c042bbb2ef3b6e25591 (diff) | |
zebra: SO_PEERCRED is a getsockopt call
This code is effectively dead code. SO_PEERCRED is a getsockopt
call not *setsockopt* call. Additionally we are not doing
anything with the failed setsockopt call at all.
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
| -rw-r--r-- | zebra/zebra_mlag_private.c | 5 |
1 files changed, 0 insertions, 5 deletions
diff --git a/zebra/zebra_mlag_private.c b/zebra/zebra_mlag_private.c index 83d0d44097..0f0285ed31 100644 --- a/zebra/zebra_mlag_private.c +++ b/zebra/zebra_mlag_private.c @@ -159,8 +159,6 @@ static int zebra_mlag_read(struct thread *thread) static int zebra_mlag_connect(struct thread *thread) { struct sockaddr_un svr = {0}; - struct ucred ucred; - socklen_t len = 0; /* Reset the Timer-running flag */ zrouter.mlag_info.timer_running = false; @@ -184,11 +182,8 @@ static int zebra_mlag_connect(struct thread *thread) &zrouter.mlag_info.t_read); return 0; } - len = sizeof(struct ucred); - ucred.pid = getpid(); set_nonblocking(mlag_socket); - setsockopt(mlag_socket, SOL_SOCKET, SO_PEERCRED, &ucred, len); if (IS_ZEBRA_DEBUG_MLAG) zlog_debug("%s: Connection with MLAG is established ", |
