]> git.baikalelectronics.ru Git - kernel.git/commit
6lowpan_rtnl: fix off by one while fragmentation
authorAlexander Aring <alex.aring@gmail.com>
Mon, 2 Jun 2014 11:21:58 +0000 (13:21 +0200)
committerDavid S. Miller <davem@davemloft.net>
Mon, 2 Jun 2014 17:39:42 +0000 (10:39 -0700)
commit5761d2d1772737e404825f1f09a601cb78c4fbe0
treee4ac32d38c2a2167a838e62b2bbe75e48d510753
parenta715cedaebe40c4d871f3f1060cc8e599fbd552f
6lowpan_rtnl: fix off by one while fragmentation

This patch fix a off by one error while fragmentation. If the frag_cap
value is equal to skb_unprocessed value we need to stop the
fragmentation loop because the last fragment which has a size of
skb_unprocessed fits into the frag capability size.

This issue was introduced by commit 87c96229bf437c70dbaedc1b8b8805a2997f930c
("6lowpan: fix fragmentation").

Signed-off-by: Alexander Aring <alex.aring@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/ieee802154/6lowpan_rtnl.c