UBI: Test return value of __wl_get_peb
In case of an error (if there are not free PEB's for example),
__wl_get_peb will return a negative value. In order to prevent access
violation we need to test the returned value prior to using it later on.
Change-Id: I3551d5cca5c61a265a34e0d11e1e185b19501024
Signed-off-by:
Tatyana Brokhman <tlinder@codeaurora.org>
Loading
Please register or sign in to comment