diff options
| author | Brian Norris <[email protected]> | 2017-06-01 17:53:55 +0000 |
|---|---|---|
| committer | Brian Norris <[email protected]> | 2017-06-01 17:53:55 +0000 |
| commit | 05e97a9eda72d58dba293857df6aac62584ef99a (patch) | |
| tree | e86e692f26d4879ff2210c54722e2b7780210249 /net/ipv6/ip6_output.c | |
| parent | Linux 4.12-rc1 (diff) | |
| parent | mtd: nand: make nand_ooblayout_lp_hamming_ops static (diff) | |
| download | kernel-05e97a9eda72d58dba293857df6aac62584ef99a.tar.gz kernel-05e97a9eda72d58dba293857df6aac62584ef99a.zip | |
Merge tag 'nand/fixes-for-4.12-rc3' of git://git.infradead.org/linux-mtd into MTD
From Boris:
"""
This pull request contains several fixes to the core and the tango
driver.
tango fixes:
* Add missing MODULE_DEVICE_TABLE() in tango_nand.c
* Update the number of corrected bitflips
core fixes:
* Fix a long standing memory leak in nand_scan_tail()
* Fix several bugs introduced by the per-vendor init/detection
infrastructure (introduced in 4.12)
* Add a static specifier to nand_ooblayout_lp_hamming_ops definition
"""
Diffstat (limited to 'net/ipv6/ip6_output.c')
| -rw-r--r-- | net/ipv6/ip6_output.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/net/ipv6/ip6_output.c b/net/ipv6/ip6_output.c index 58f6288e9ba5..d4a31becbd25 100644 --- a/net/ipv6/ip6_output.c +++ b/net/ipv6/ip6_output.c @@ -597,7 +597,10 @@ int ip6_fragment(struct net *net, struct sock *sk, struct sk_buff *skb, int ptr, offset = 0, err = 0; u8 *prevhdr, nexthdr = 0; - hlen = ip6_find_1stfragopt(skb, &prevhdr); + err = ip6_find_1stfragopt(skb, &prevhdr); + if (err < 0) + goto fail; + hlen = err; nexthdr = *prevhdr; mtu = ip6_skb_dst_mtu(skb); |
