diff options
Diffstat (limited to 'net/phonet/pep.c')
-rw-r--r-- | net/phonet/pep.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/net/phonet/pep.c b/net/phonet/pep.c index 9f60008740e3..9726fe684ab8 100644 --- a/net/phonet/pep.c +++ b/net/phonet/pep.c | |||
@@ -1130,6 +1130,9 @@ static int pep_sendmsg(struct kiocb *iocb, struct sock *sk, | |||
1130 | int flags = msg->msg_flags; | 1130 | int flags = msg->msg_flags; |
1131 | int err, done; | 1131 | int err, done; |
1132 | 1132 | ||
1133 | if (len > USHRT_MAX) | ||
1134 | return -EMSGSIZE; | ||
1135 | |||
1133 | if ((msg->msg_flags & ~(MSG_DONTWAIT|MSG_EOR|MSG_NOSIGNAL| | 1136 | if ((msg->msg_flags & ~(MSG_DONTWAIT|MSG_EOR|MSG_NOSIGNAL| |
1134 | MSG_CMSG_COMPAT)) || | 1137 | MSG_CMSG_COMPAT)) || |
1135 | !(msg->msg_flags & MSG_EOR)) | 1138 | !(msg->msg_flags & MSG_EOR)) |