diff options
| author | Dan Carpenter <[email protected]> | 2024-02-08 10:18:46 +0000 |
|---|---|---|
| committer | Steve French <[email protected]> | 2024-02-12 01:07:08 +0000 |
| commit | cffe487026be13eaf37ea28b783d9638ab147204 (patch) | |
| tree | 27bc2db68a43e966b53061831d3bfe633654fa70 /scripts/clang-tools/gen_compile_commands.py | |
| parent | Linux 6.8-rc4 (diff) | |
| download | kernel-cffe487026be13eaf37ea28b783d9638ab147204.tar.gz kernel-cffe487026be13eaf37ea28b783d9638ab147204.zip | |
cifs: fix underflow in parse_server_interfaces()
In this loop, we step through the buffer and after each item we check
if the size_left is greater than the minimum size we need. However,
the problem is that "bytes_left" is type ssize_t while sizeof() is type
size_t. That means that because of type promotion, the comparison is
done as an unsigned and if we have negative bytes left the loop
continues instead of ending.
Fixes: fe856be475f7 ("CIFS: parse and store info on iface queries")
Signed-off-by: Dan Carpenter <[email protected]>
Reviewed-by: Shyam Prasad N <[email protected]>
Signed-off-by: Steve French <[email protected]>
Diffstat (limited to 'scripts/clang-tools/gen_compile_commands.py')
0 files changed, 0 insertions, 0 deletions
