diff options
| author | Andrzej Zaborowski <andrew.zaborowski@intel.com> | 2015-11-13 12:01:32 +0100 |
|---|---|---|
| committer | Mister Oyster <oysterized@gmail.com> | 2017-12-22 16:23:43 +0100 |
| commit | 41aeb7c62d202405f6b245dd2e26147c4a9b8601 (patch) | |
| tree | cbc4815b80716bad4d03f42ede703da48240e0a6 /scripts/checkstack.pl | |
| parent | d1ba7ebedb54095bf5ce3017ba039091babd721b (diff) | |
lib/mpi: only require buffers as big as needed for the integer
Since mpi_write_to_sgl and mpi_read_buffer explicitly left-align the
integers being written it makes no sense to require a buffer big enough for
the number + the leading zero bytes which are not written. The error
returned also doesn't convey any information. So instead require only the
size needed and return -EOVERFLOW to signal when buffer too short.
Signed-off-by: Andrew Zaborowski <andrew.zaborowski@intel.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Diffstat (limited to 'scripts/checkstack.pl')
0 files changed, 0 insertions, 0 deletions
