Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 211406
b: refs/heads/master
c: 51e97a1
h: refs/heads/master
v: v3
  • Loading branch information
Dan Rosenberg authored and David S. Miller committed Oct 4, 2010
1 parent cecfcd3 commit 096a55b
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 3 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: d7e0d19aa0fdd22819d35db551bd54c1bcf9c2aa
refs/heads/master: 51e97a12bef19b7e43199fc153cf9bd5f2140362
8 changes: 6 additions & 2 deletions trunk/net/sctp/auth.c
Original file line number Diff line number Diff line change
Expand Up @@ -543,16 +543,20 @@ struct sctp_hmac *sctp_auth_asoc_get_hmac(const struct sctp_association *asoc)
id = ntohs(hmacs->hmac_ids[i]);

/* Check the id is in the supported range */
if (id > SCTP_AUTH_HMAC_ID_MAX)
if (id > SCTP_AUTH_HMAC_ID_MAX) {
id = 0;
continue;
}

/* See is we support the id. Supported IDs have name and
* length fields set, so that we can allocated and use
* them. We can safely just check for name, for without the
* name, we can't allocate the TFM.
*/
if (!sctp_hmac_list[id].hmac_name)
if (!sctp_hmac_list[id].hmac_name) {
id = 0;
continue;
}

break;
}
Expand Down

0 comments on commit 096a55b

Please sign in to comment.