diff options
| author | Florian Westphal <fw@strlen.de> | 2026-03-30 14:27:39 +0200 |
|---|---|---|
| committer | Jason Gunthorpe <jgg@nvidia.com> | 2026-04-09 10:58:56 -0300 |
| commit | 6ed3d14fc45d3da6025e7fe4a6a09066856698e2 (patch) | |
| tree | 438d0875ceffa793e584401b2d2eda5158acba1c /include/linux/i2c/git@git.tavy.me:linux-stable.git | |
| parent | 973403ca3553f0367a6982687f5f0ee4212e9ab9 (diff) | |
RDMA/core: Prefer NLA_NUL_STRING
These attributes are evaluated as c-string (passed to strcmp), but
NLA_STRING doesn't check for the presence of a \0 terminator.
Either this needs to switch to nla_strcmp() and needs to adjust printf fmt
specifier to not use plain %s, or this needs to use NLA_NUL_STRING.
As the code has been this way for long time, it seems to me that userspace
does include the terminating nul, even tough its not enforced so far, and
thus NLA_NUL_STRING use is the simpler solution.
Fixes: 30dc5e63d6a5 ("RDMA/core: Add support for iWARP Port Mapper user space service")
Link: https://patch.msgid.link/r/20260330122742.13315-1-fw@strlen.de
Signed-off-by: Florian Westphal <fw@strlen.de>
Signed-off-by: Jason Gunthorpe <jgg@nvidia.com>
Diffstat (limited to 'include/linux/i2c/git@git.tavy.me:linux-stable.git')
0 files changed, 0 insertions, 0 deletions
