diff options
| author | Ian Abbott <[email protected]> | 2015-10-12 17:21:24 +0100 |
|---|---|---|
| committer | Greg Kroah-Hartman <[email protected]> | 2015-10-13 10:29:48 -0700 |
| commit | 8ea939284d3ebde02d5b46d50406c2b7faae1214 (patch) | |
| tree | 74f90531d32eb15b673d6882f9783aeae893b6dc /tools/perf/scripts/python/call-graph-from-postgresql.py | |
| parent | 76e8e7d4ffb3300217b62637183282a5225d7394 (diff) | |
staging: comedi: avoid bad truncation of a size_t in comedi_read()
At one point in `comedi_read()`, the variable `n` gets assigned to the
minimum of the parameter `nbytes` and the amount of readable buffer
space `m`. The way that is done currently is unsafe in the unlikely
case that `nbytes` exceeds `UINT_MAX`, so fix it.
Signed-off-by: Ian Abbott <[email protected]>
Reviewed-by: H Hartley Sweeten <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python/call-graph-from-postgresql.py')
0 files changed, 0 insertions, 0 deletions