Merge "NFC: remove unnecessary branching" into main am: 8e631624e9

Original change: https://android-review.googlesource.com/c/platform/bionic/+/2940087

Change-Id: I436a3a87b36753b944fc1a95e18b3f5d83e0d071
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
Treehugger Robot 2024-02-01 20:19:01 +00:00 committed by Automerger Merge Worker
commit 7995a74a3d

View file

@ -90,10 +90,7 @@ static bool set_tcf_on_all_threads(int tcf) {
}
tagged_addr_ctrl = (tagged_addr_ctrl & ~PR_MTE_TCF_MASK) | tcf;
if (prctl(PR_SET_TAGGED_ADDR_CTRL, tagged_addr_ctrl, 0, 0, 0) < 0) {
return false;
}
return true;
return prctl(PR_SET_TAGGED_ADDR_CTRL, tagged_addr_ctrl, 0, 0, 0) >= 0;
},
&tcf);
}