Normally ADN record is stored in two tags, EFADN_TAG and EFEXT1_TAG. But if the EFEXT1_TAG is not set in EF_PBR entry,
it shouldn't be decoded otherwise it causes NullPointerException in readAdnFileAndWait().
bug:
3376954
Change-Id: I744cf5cb8662c75be1e7c6219fa92c67bdda82f2
fileIds = mPbrFile.mFileIds.get(recNum);
if (fileIds == null || fileIds.isEmpty()) return;
+
+ int extEf = 0;
+ // Only call fileIds.get while EFEXT1_TAG is available
+ if (fileIds.containsKey(USIM_EFEXT1_TAG)) {
+ extEf = fileIds.get(USIM_EFEXT1_TAG);
+ }
+
mAdnCache.requestLoadAllAdnLike(fileIds.get(USIM_EFADN_TAG),
- fileIds.get(USIM_EFEXT1_TAG), obtainMessage(EVENT_USIM_ADN_LOAD_DONE));
+ extEf, obtainMessage(EVENT_USIM_ADN_LOAD_DONE));
try {
mLock.wait();
} catch (InterruptedException e) {