Skip to content
Commit d8b59efa authored by Paolo Abeni's avatar Paolo Abeni Committed by David S. Miller
Browse files

mptcp: init mptcp request socket earlier



The mptcp subflow route_req() callback performs the subflow
req initialization after the route_req() check. If the latter
fails, mptcp-specific bits of the current request sockets
are left uninitialized.

The above causes bad things at req socket disposal time, when
the mptcp resources are cleared.

This change addresses the issue by splitting subflow_init_req()
into the actual initialization and the mptcp-specific checks.
The initialization is moved before any possibly failing check.

Reported-by: default avatarChristoph Paasch <cpaasch@apple.com>
Fixes: 7ea851d1

 ("tcp: merge 'init_req' and 'route_req' functions")
Signed-off-by: default avatarPaolo Abeni <pabeni@redhat.com>
Signed-off-by: default avatarMat Martineau <mathew.j.martineau@linux.intel.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 64b9cea7
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment