Skip to content
Snippets Groups Projects
Commit e2d64d8a authored by liuchao's avatar liuchao Committed by Marie Janssen
Browse files

Fix an inappropriate sscanf return value judgment

This fixes an inappropriate sscanf return value judgment that
res check here is not needed while res2 is the one that need to be checked

Test: mm -j 8
Change-Id: I3e332286c9434d5b9d01421f5f421039f84ad6c7
parent 12ad6378
No related branches found
No related tags found
No related merge requests found
......@@ -1246,7 +1246,7 @@ static char* bta_hf_client_parse_clcc(tBTA_HF_CLIENT_CB* client_cb,
if (res2 == 0) {
res2 = sscanf(buffer, ",\"\",%hu%n", &type, &offset);
if (res < 0) return NULL;
if (res2 < 0) return NULL;
/* numstr is not matched in second attempt, correct this */
res2++;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment