diff options
author | Heinrich Schuchardt <xypron.glpk@gmx.de> | 2019-03-19 18:58:58 +0100 |
---|---|---|
committer | Heinrich Schuchardt <xypron.glpk@gmx.de> | 2019-03-20 18:16:53 +0100 |
commit | d5974af7f7626777b5c41894f75c813ff35c1793 (patch) | |
tree | 9c73b89058da4dd5d604396c26d2fa28338e384d /lib | |
parent | 1fd7a4764103781e424ef687034da06de3cb60b7 (diff) | |
download | u-boot-d5974af7f7626777b5c41894f75c813ff35c1793.tar.gz u-boot-d5974af7f7626777b5c41894f75c813ff35c1793.tar.bz2 u-boot-d5974af7f7626777b5c41894f75c813ff35c1793.zip |
efi_loader: remove superfluous check in efi_setup_loaded_image()
It does not make any sense to check if a pointer is NULL if we have
dereferenced it before.
Reported-by: Coverity (CID 185827)
Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Diffstat (limited to 'lib')
-rw-r--r-- | lib/efi_loader/efi_boottime.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/lib/efi_loader/efi_boottime.c b/lib/efi_loader/efi_boottime.c index bd8b8a17ae..4fc550d9f3 100644 --- a/lib/efi_loader/efi_boottime.c +++ b/lib/efi_loader/efi_boottime.c @@ -1581,10 +1581,8 @@ efi_status_t efi_setup_loaded_image(struct efi_device_path *device_path, goto failure; #endif - if (info_ptr) - *info_ptr = info; - if (handle_ptr) - *handle_ptr = obj; + *info_ptr = info; + *handle_ptr = obj; return ret; failure: |