diff options
author | Aleksander Morgado <aleksandermj@chromium.org> | 2022-11-03 23:31:53 +0000 |
---|---|---|
committer | Aleksander Morgado <aleksandermj@chromium.org> | 2022-11-03 23:42:48 +0000 |
commit | 823f3e7995a27d89524f07aee46c8efad246fbc7 (patch) | |
tree | 2e15f71512973c1557ecb65f738ddf0eae13425f /src/mm-sleep-monitor-powerd.c | |
parent | 4bb601dd2f6b522e0881a5e8b081bd104b7bfd2c (diff) |
base-sim: fix length when reading GID1/GID2
We were attempting to read 15 bytes unconditionally, regardless of the
size of the EF_gid1 and EF_gid2 files.
This operation would succeed in some SIM cards even if the actual file
lengths are shorter:
AT+CRSM=176,28478,0,0,15
+CRSM: 144,0,"FFFF"
OK
But the operation would fail in some other SIM cards due to the length
mismatch:
AT+CRSM=176,28478,0,0,15
+CRSM: 103,0
OK
Using 0 as requested length instructs the modem to read the length
specified in the EF status information, which is also the same
approach we do in QMI and MBIM.
AT+CRSM=176,28478,0,0,0
+CRSM: 144,0,"FFFF"
OK
Diffstat (limited to 'src/mm-sleep-monitor-powerd.c')
0 files changed, 0 insertions, 0 deletions