Skip to content
Commit 6a3602a3 authored by Jonathan Rico's avatar Jonathan Rico Committed by Anas Nashif
Browse files

net: buf: Clear `user_data` on allocation



For two reasons:
- prevent exposing the previous user's info to the new user
- make NULL checks on user_data work

Since we don't really have a field that specifies what part of the
user_data array is valid, we have to rely on other checks.

Such a check, if user_data contains a callback, is comparing against
NULL before calling said callback.

Signed-off-by: default avatarJonathan Rico <jonathan.rico@nordicsemi.no>
parent 1c28ded7
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment