diff options
| author | Niels Dossche <[email protected]> | 2022-06-14 18:50:02 +0100 |
|---|---|---|
| committer | Mauro Carvalho Chehab <[email protected]> | 2022-06-27 09:02:50 +0100 |
| commit | 359c27c6ddbde404f44a9c0d3ec88ccd1e2042f2 (patch) | |
| tree | 8d6fcbf1ab2b196e3a92128e9ec09a79e86d2334 /tools/perf/scripts/python/event_analyzing_sample.py | |
| parent | 63249a5cab81b69d43b0a508eb597e7be6f5343a (diff) | |
media: hdpvr: fix error value returns in hdpvr_read
Error return values are supposed to be negative in hdpvr_read. Most
error returns are currently handled via an unsigned integer "ret". When
setting a negative error value to "ret", the value actually becomes a
large positive value, because "ret" is unsigned. Later on, the "ret"
value is returned. But as ssize_t is a 64-bit signed number, the error
return value stays a large positive integer instead of a negative
integer. This can cause an error value to be interpreted as the read
size, which can cause a buffer overread for applications relying on the
returned size.
Fixes: 9aba42efe85b ("V4L/DVB (11096): V4L2 Driver for the Hauppauge HD PVR usb capture device")
Signed-off-by: Niels Dossche <[email protected]>
Signed-off-by: Hans Verkuil <[email protected]>
Signed-off-by: Mauro Carvalho Chehab <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python/event_analyzing_sample.py')
0 files changed, 0 insertions, 0 deletions