diff options
author | Stephen Warren <swarren@nvidia.com> | 2016-02-04 11:54:20 -0700 |
---|---|---|
committer | Tom Rini <trini@konsulko.com> | 2016-02-08 10:22:38 -0500 |
commit | ee05fedc6c89a41cad19b626fcde0b70ad532ea2 (patch) | |
tree | d79da2579de81367de1b3da7b66ef5b9abc6e0e1 /fs/reiserfs | |
parent | 7c60423106bebafedbdd9879d84d105b3fb03930 (diff) | |
download | u-boot-ee05fedc6c89a41cad19b626fcde0b70ad532ea2.zip u-boot-ee05fedc6c89a41cad19b626fcde0b70ad532ea2.tar.gz u-boot-ee05fedc6c89a41cad19b626fcde0b70ad532ea2.tar.bz2 |
malloc: solve dead code issue in memalign()
The recent change to memalign() caused the allocation failure detection
code to be dead code; the "retry" logic is always activated under the same
condition that the original failure detection code is, and also fully
handles any possible failures. This patch solves the presence of dead
code.
Two alternatives are possible:
a) Delete the now-dead test, and rely on the "retry" path to handle any
allocation problems, as it does.
b) Make the "retry" path fall through to the existing (currently dead)
failure detection code, thus making it not-dead.
(b) was chosen since it reduces the diff between U-Boot's and the upstream
dlmalloc. This should make it marginally easier to import a new version of
dlmalloc in the future.
Reported by: Coverity Scan
Fixes: 4f144a416469 ("malloc: work around some memalign fragmentation issues")
Signed-off-by: Stephen Warren <swarren@nvidia.com>
Reviewed-by: Tom Rini <trini@konsulko.com>
Diffstat (limited to 'fs/reiserfs')
0 files changed, 0 insertions, 0 deletions