Skip to content

mptcp: fix error handling rp_filter when kernel don't support mptcp

eagle gai requested to merge eaglegai/NetworkManager:main into main

Summary

mptcp: fix error handling rp_filter when kernel don't support mptcp

Purpose

when the kernel don't support mptcp, NetworkManager should disable mptcp and shouldn't change rp_filter from 1 to 2, but when checking file /proc/sys/net/mptcp/enabled,val v is defined to guint32, and nm_platform_sysctl_get_int32 return -1, so v becomes a very large number and can't set mptcp_flags to NM_MPTCP_FLAGS_DISABLED.

fix #1686 (closed)

Checklist

Please read https://gitlab.freedesktop.org/NetworkManager/NetworkManager/-/blob/main/CONTRIBUTING.md before opening the merge request. In particular, check that:

  • the subject for all commits is concise and explicative
  • the message for all commits explains the reason for the change
  • the source is properly formatted
  • any relevant documentation is up to date
  • you have added unit tests if applicable
  • the NEWS file is updated when the change deserves to be mentioned, for example for new features, behavior changes, API deprecations, etc.

Merge request reports

Loading