1
0
mirror of https://github.com/systemd/systemd.git synced 2024-10-27 10:25:37 +03:00

capability: also cap CAP_LAST_CAP at 63

This commit is contained in:
Lennart Poettering 2019-03-21 12:37:30 +01:00
parent 664ff517d3
commit 46eda04373

View File

@ -61,7 +61,7 @@ unsigned long cap_last_cap(void) {
}
/* fall back to syscall-probing for pre linux-3.2 */
p = (unsigned long) CAP_LAST_CAP;
p = MIN((unsigned long) CAP_LAST_CAP, 63U);
if (prctl(PR_CAPBSET_READ, p) < 0) {