freebsd-skq/sys/net
cem 5abde16df3 radix_mpath: Don't derefence a NULL pointer in for loop iteration
It seems rn_dupedkey may be NULL, because of the NULL check inside the loop.
(Also, the rt gets assigned from rn_dupedkey and NULL checked at top of loop.)
However, the for-loop update condition happens before the top-of-loop check and
dereferences 'rt' unconditionally.

Instead, NULL-check before dereferencing.

If rn_dupedkey cannot in fact be NULL, or something else protects this, feel
free to revert this and add an ASSERT of some kind instead.

This was introduced in r191080 (2009) and moved around slightly in r293657.

Reported by:	Coverity
CID:		1348482
Sponsored by:	EMC / Isilon Storage Division
2016-04-26 20:27:17 +00:00
..
altq Fix the spelling of eri's name. 2015-08-24 23:40:36 +00:00
bpf_buffer.c Remove the sleep from the buffer allocation routine. 2015-07-31 20:25:54 +00:00
bpf_buffer.h
bpf_filter.c sys/net* : for pointers replace 0 with NULL. 2016-04-15 17:30:33 +00:00
bpf_jitter.c
bpf_jitter.h
bpf_zerocopy.c
bpf_zerocopy.h
bpf.c sys: use our roundup2/rounddown2() macros when param.h is available. 2016-04-21 19:57:40 +00:00
bpf.h During if_vmove() we call if_detach_internal() which in turn calls the event 2016-04-11 10:00:38 +00:00
bpfdesc.h
bridgestp.c These files were getting sys/malloc.h and vm/uma.h with header pollution 2016-02-01 17:41:21 +00:00
bridgestp.h
ethernet.h Add ethertype reserved for network testing 2016-03-28 18:25:54 +00:00
fddi.h
firewire.h
flowtable.c Implement interface link header precomputation API. 2015-12-31 05:03:27 +00:00
flowtable.h
ieee8023ad_lacp.c Add sysctl to control LACP strict compliance default 2015-11-06 15:33:27 +00:00
ieee8023ad_lacp.h Make LAG LACP fast timeout tunable through IOCTL. 2015-08-12 20:21:04 +00:00
ieee_oui.h
if_arc.h
if_arcsubr.c sys: extend use of the howmany() macro when available. 2016-04-26 15:38:17 +00:00
if_arp.h
if_atm.h
if_atmsubr.c sys/net* : for pointers replace 0 with NULL. 2016-04-15 17:30:33 +00:00
if_bridge.c sys/net* : for pointers replace 0 with NULL. 2016-04-15 17:30:33 +00:00
if_bridgevar.h
if_clone.c Fix group membership of cloned interfaces when one is moved by 2015-03-02 20:00:03 +00:00
if_clone.h Fix group membership of cloned interfaces when one is moved by 2015-03-02 20:00:03 +00:00
if_dead.c Provide a dead version of if_get_counter. 2014-12-12 16:10:42 +00:00
if_debug.c Add more fields from struct ifnet needed during debugging a kernel panic. 2016-04-20 21:04:39 +00:00
if_disc.c sys/net* : for pointers replace 0 with NULL. 2016-04-15 17:30:33 +00:00
if_dl.h Constantify lookup key in ifa_ifwith* functions. 2015-09-05 05:33:20 +00:00
if_edsc.c
if_enc.c Fix building sys/modules/if_enc by adding missing headers 2015-11-25 21:16:10 +00:00
if_enc.h Overhaul if_enc(4) and make it loadable in run-time. 2015-11-25 07:31:59 +00:00
if_epair.c These files were getting sys/malloc.h and vm/uma.h with header pollution 2016-02-01 17:41:21 +00:00
if_ethersubr.c sys/net* : for pointers replace 0 with NULL. 2016-04-15 17:30:33 +00:00
if_fddisubr.c sys/net* : for pointers replace 0 with NULL. 2016-04-15 17:30:33 +00:00
if_fwsubr.c sys/net* : for pointers replace 0 with NULL. 2016-04-15 17:30:33 +00:00
if_gif.c Cleanup unnecessary semicolons from the kernel. 2016-04-10 23:07:00 +00:00
if_gif.h - Remove GIF_{SEND,ACCEPT}_REVETHIP. 2015-09-10 05:59:39 +00:00
if_gre.c Cleanup unnecessary semicolons from the kernel. 2016-04-10 23:07:00 +00:00
if_gre.h Extern declarations in C files loses compile-time checking that 2014-12-25 21:32:37 +00:00
if_iso88025subr.c sys/net* : for pointers replace 0 with NULL. 2016-04-15 17:30:33 +00:00
if_lagg.c Revert accidental submit of WIP as part of r297609 2016-04-06 04:58:20 +00:00
if_lagg.h Revert accidental submit of WIP as part of r297609 2016-04-06 04:58:20 +00:00
if_llatbl.c Implement interface link header precomputation API. 2015-12-31 05:03:27 +00:00
if_llatbl.h Implement interface link header precomputation API. 2015-12-31 05:03:27 +00:00
if_llc.h
if_loop.c sys/net* : for pointers replace 0 with NULL. 2016-04-15 17:30:33 +00:00
if_me.c Add IFCAP_LINKSTATE support. 2015-10-03 09:15:23 +00:00
if_media.c Make IFMEDIA_DEBUG a kernel option. 2015-04-21 10:35:23 +00:00
if_media.h ifmedia changes: 2015-04-07 21:31:17 +00:00
if_mib.c These files were getting sys/malloc.h and vm/uma.h with header pollution 2016-02-01 17:41:21 +00:00
if_mib.h
if_pflog.h
if_pfsync.h
if_sppp.h
if_spppfr.c
if_spppsubr.c sys/net* : for pointers replace 0 with NULL. 2016-04-15 17:30:33 +00:00
if_stf.c Convert if_stf(4) to new routing api. 2015-12-16 09:18:20 +00:00
if_tap.c if_tap: correct typo in sysctl description (Enably) 2015-10-21 19:56:16 +00:00
if_tap.h
if_tapvar.h
if_tun.c * Address review (and add a bit myself). 2015-07-12 18:14:38 +00:00
if_tun.h
if_types.h After r281643 an #ifdef IFT_FOO preprocessor directive returns false, 2015-05-02 20:37:40 +00:00
if_var.h Implement interface link header precomputation API. 2015-12-31 05:03:27 +00:00
if_vlan_var.h
if_vlan.c Move iflladdr_event eventhandler invocation to if_setlladdr. 2015-11-14 13:34:03 +00:00
if_vxlan.c Start process of removing the use of the deprecated "M_FLOWID" flag 2014-12-01 11:45:24 +00:00
if_vxlan.h
if.c sys/net* : for pointers replace 0 with NULL. 2016-04-15 17:30:33 +00:00
if.h
ifq.h buf_ring/drbr: Add buf_ring_peek_clear_sc and use it in drbr_peek 2016-02-29 03:54:51 +00:00
iso88025.h
netisr_internal.h
netisr.c Remove slightly used const values that can be replaced with nitems(). 2016-04-21 15:38:28 +00:00
netisr.h
netmap_user.h Sync netmap sources with the version in our private tree. 2015-07-10 05:51:36 +00:00
netmap.h Sync netmap sources with the version in our private tree. 2015-07-10 05:51:36 +00:00
paravirt.h
pfil.c
pfil.h
pfkeyv2.h Implement the sadb_x_policy_priority field as it is done in Linux: 2015-11-17 14:39:33 +00:00
pfvar.h These files were getting sys/malloc.h and vm/uma.h with header pollution 2016-02-01 17:41:21 +00:00
ppp_defs.h
radix_mpath.c radix_mpath: Don't derefence a NULL pointer in for loop iteration 2016-04-26 20:27:17 +00:00
radix_mpath.h MFP r287070,r287073: split radix implementation and route table structure. 2016-01-25 06:33:15 +00:00
radix.c radix rn_inithead: Fix minor leak in low memory conditions 2016-04-20 02:01:45 +00:00
radix.h MFP r287070,r287073: split radix implementation and route table structure. 2016-01-25 06:33:15 +00:00
raw_cb.c
raw_cb.h
raw_usrreq.c sys/net* : for pointers replace 0 with NULL. 2016-04-15 17:30:33 +00:00
route_var.h FreeBSD previously provided route caching for TCP (and UDP). Re-add 2016-03-24 07:54:56 +00:00
route.c Fix compile errors after r297225: 2016-03-24 11:40:10 +00:00
route.h Fix compile errors after r297225: 2016-03-24 11:40:10 +00:00
rss_config.c Remove now unused (and #if 0'ed out) headers. 2015-08-29 04:33:31 +00:00
rss_config.h Replace the printf()s with optional rate limited debugging for RSS. 2015-08-28 05:58:16 +00:00
rtsock.c kernel: use our nitems() macro when it is available through param.h. 2016-04-19 23:48:27 +00:00
sff8436.h Add SFF-8024 Extended Specification Compliance 2015-12-28 09:26:07 +00:00
sff8472.h * Update SFF-8024 Identifier constants. 2015-05-16 13:11:35 +00:00
slcompress.c
slcompress.h
toeplitz.c Refactor / restructure the RSS code into generic, IPv4 and IPv6 specific 2015-01-18 18:06:40 +00:00
toeplitz.h Refactor / restructure the RSS code into generic, IPv4 and IPv6 specific 2015-01-18 18:06:40 +00:00
vnet.c Prune a definition which is / was never used. 2016-01-25 20:35:15 +00:00
vnet.h Provide TCPSTAT_DEC() and TCPSTAT_FETCH() macros. 2016-01-27 00:20:07 +00:00