diff options
Diffstat (limited to 'include/net/scm.h')
| -rw-r--r-- | include/net/scm.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/include/net/scm.h b/include/net/scm.h index b7ba74dbc3fd..c3fa3d5ab606 100644 --- a/include/net/scm.h +++ b/include/net/scm.h @@ -51,13 +51,13 @@ static __inline__ void scm_recv(struct socket *sock, struct msghdr *msg, { if (!msg->msg_control) { - if (sock->passcred || scm->fp) + if (test_bit(SOCK_PASSCRED, &sock->flags) || scm->fp) msg->msg_flags |= MSG_CTRUNC; scm_destroy(scm); return; } - if (sock->passcred) + if (test_bit(SOCK_PASSCRED, &sock->flags)) put_cmsg(msg, SOL_SOCKET, SCM_CREDENTIALS, sizeof(scm->creds), &scm->creds); if (!scm->fp) |
