diff options
author | Dan Carpenter <[email protected]> | 2024-02-09 16:02:16 +0300 |
---|---|---|
committer | Mark Brown <[email protected]> | 2024-02-14 13:22:24 +0000 |
commit | 98f681b0f84cfc3a1d83287b77697679e0398306 (patch) | |
tree | 1d9cc2d4c9d5a34a3154aae723dc063b538e3e0e /lib/test_fortify/write_overflow-strncpy-src.c | |
parent | 81ff296a8163ed791fd05a3dba1a826c598a3c84 (diff) |
ASoC: SOF: Add some bounds checking to firmware data
Smatch complains about "head->full_size - head->header_size" can
underflow. To some extent, we're always going to have to trust the
firmware a bit. However, it's easy enough to add a check for negatives,
and let's add a upper bounds check as well.
Fixes: d2458baa799f ("ASoC: SOF: ipc3-loader: Implement firmware parsing and loading")
Signed-off-by: Dan Carpenter <[email protected]>
Link: https://msgid.link/r/[email protected]
Signed-off-by: Mark Brown <[email protected]>
Diffstat (limited to 'lib/test_fortify/write_overflow-strncpy-src.c')
0 files changed, 0 insertions, 0 deletions