Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit 0e5d7184 authored by Syed Zaidi's avatar Syed Zaidi
Browse files

SystemCertificateSource: Mitigate NPE when checking updateable certs directory



The updateable conscrypt APEX certificate store located at /apex/com.android.conscrypt/cacert may be empty.
Previously we would check whether or not the folder is empty by determinimg if the length of the returned list[]
array was non-zero. However, when a directory is empty, a null value is returned instead of an empty array. We
rectify that here by utilizing the helper function ArrayUtils.isEmpty() instead of manually checking the length.

Flag: NONE
Test: atest NetworkSecurityConfigTests

Change-Id: I3557f75aa5a807623df6e978145c4378f06c625b
Signed-off-by: default avatarSyed Zaidi <zaidisyed@meta.com>
parent e74cf64e
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment