From: Ivan Vecera <ivecera@redhat.com> Date: 2021-10-28 15:58:50
Function br_get_link_af_size_filtered() calls br_cfm_{,peer}_mep_count()
that return a count. When BRIDGE_CFM is not enabled these functions
simply return -EOPNOTSUPP but do not modify count parameter and
calling function then works with uninitialized variables.
Modify these inline functions to return zero in count parameter.
Fixes: b6d0425b816e ("bridge: cfm: Netlink Notifications.")
Cc: Henrik Bjoernlund <redacted>
Signed-off-by: Ivan Vecera <ivecera@redhat.com>
---
net/bridge/br_private.h | 2 ++
1 file changed, 2 insertions(+)
From: Nikolay Aleksandrov <hidden> Date: 2021-10-28 16:01:07
On 28/10/2021 18:58, Ivan Vecera wrote:
quoted hunk
Function br_get_link_af_size_filtered() calls br_cfm_{,peer}_mep_count()
that return a count. When BRIDGE_CFM is not enabled these functions
simply return -EOPNOTSUPP but do not modify count parameter and
calling function then works with uninitialized variables.
Modify these inline functions to return zero in count parameter.
Fixes: b6d0425b816e ("bridge: cfm: Netlink Notifications.")
Cc: Henrik Bjoernlund <redacted>
Signed-off-by: Ivan Vecera <ivecera@redhat.com>
---
net/bridge/br_private.h | 2 ++
1 file changed, 2 insertions(+)
Hello:
This patch was applied to netdev/net.git (master)
by David S. Miller [off-list ref]:
On Thu, 28 Oct 2021 17:58:35 +0200 you wrote:
Function br_get_link_af_size_filtered() calls br_cfm_{,peer}_mep_count()
that return a count. When BRIDGE_CFM is not enabled these functions
simply return -EOPNOTSUPP but do not modify count parameter and
calling function then works with uninitialized variables.
Modify these inline functions to return zero in count parameter.
Fixes: b6d0425b816e ("bridge: cfm: Netlink Notifications.")
Cc: Henrik Bjoernlund <redacted>
Signed-off-by: Ivan Vecera <ivecera@redhat.com>
[...]