Gitweb: http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=b16be51b5e5d75cec71b18ebc75f15a4734c62ad Commit: b16be51b5e5d75cec71b18ebc75f15a4734c62ad Parent: d52de17b8cf36d43a9d6977e7861a9f415541c6b Author: Gerrit Renker <[EMAIL PROTECTED]> AuthorDate: Tue Mar 20 13:03:47 2007 -0300 Committer: David S. Miller <[EMAIL PROTECTED]> CommitDate: Wed Apr 25 22:26:45 2007 -0700
[DCCP]: Fix for follows48 The follows48 relation identifies whether 48-bit sequence number x is the direct successor of y. Currently, it does not handle cases of the following type correctly: follows48(0x(prefix)10000LL, 0x(prefix)0FFFFLL) where prefix is an arbitrary hex sequence of up to 7 digits. This is fixed by reusing the new dccp_delta_seqno function. Signed-off-by: Gerrit Renker <[EMAIL PROTECTED]> Acked-by: Ian McDonald <[EMAIL PROTECTED]> Signed-off-by: Arnaldo Carvalho de Melo <[EMAIL PROTECTED]> Signed-off-by: David S. Miller <[EMAIL PROTECTED]> --- net/dccp/dccp.h | 4 +--- 1 files changed, 1 insertions(+), 3 deletions(-) diff --git a/net/dccp/dccp.h b/net/dccp/dccp.h index 1615986..c66a458 100644 --- a/net/dccp/dccp.h +++ b/net/dccp/dccp.h @@ -144,9 +144,7 @@ static inline u64 max48(const u64 seq1, const u64 seq2) /* is seq1 next seqno after seq2 */ static inline int follows48(const u64 seq1, const u64 seq2) { - int diff = (seq1 & 0xFFFF) - (seq2 & 0xFFFF); - - return diff==1; + return dccp_delta_seqno(seq2, seq1) == 1; } enum { - To unsubscribe from this list: send the line "unsubscribe git-commits-head" in the body of a message to [EMAIL PROTECTED] More majordomo info at http://vger.kernel.org/majordomo-info.html