Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 352494
b: refs/heads/master
c: 97f8b87
h: refs/heads/master
v: v3
  • Loading branch information
Ying Xue authored and Paul Gortmaker committed Feb 15, 2013
1 parent d4770bf commit a288038
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 7 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: aba79f332f46ca8529f3e62a9fc2926c8fe75e44
refs/heads/master: 97f8b87e9108485a0b7070645662253561304458
9 changes: 3 additions & 6 deletions trunk/net/tipc/socket.c
Original file line number Diff line number Diff line change
Expand Up @@ -503,8 +503,7 @@ static int send_msg(struct kiocb *iocb, struct socket *sock,
if (unlikely((m->msg_namelen < sizeof(*dest)) ||
(dest->family != AF_TIPC)))
return -EINVAL;
if ((total_len > TIPC_MAX_USER_MSG_SIZE) ||
(m->msg_iovlen > (unsigned int)INT_MAX))
if (total_len > TIPC_MAX_USER_MSG_SIZE)
return -EMSGSIZE;

if (iocb)
Expand Down Expand Up @@ -612,8 +611,7 @@ static int send_packet(struct kiocb *iocb, struct socket *sock,
if (unlikely(dest))
return send_msg(iocb, sock, m, total_len);

if ((total_len > TIPC_MAX_USER_MSG_SIZE) ||
(m->msg_iovlen > (unsigned int)INT_MAX))
if (total_len > TIPC_MAX_USER_MSG_SIZE)
return -EMSGSIZE;

if (iocb)
Expand Down Expand Up @@ -698,8 +696,7 @@ static int send_stream(struct kiocb *iocb, struct socket *sock,
goto exit;
}

if ((total_len > (unsigned int)INT_MAX) ||
(m->msg_iovlen > (unsigned int)INT_MAX)) {
if (total_len > (unsigned int)INT_MAX) {
res = -EMSGSIZE;
goto exit;
}
Expand Down

0 comments on commit a288038

Please sign in to comment.