mirror of
https://github.com/pi-hole/FTL.git
synced 2024-10-26 16:52:18 +02:00
Also check for capabilities CAP_IPC_LOCK and CAP_CHOWN
Signed-off-by: DL6ER <dl6er@dl6er.de>
This commit is contained in:
@@ -99,6 +99,18 @@ bool check_capabilities(void)
|
||||
logg("WARNING: Required Linux capability CAP_SYS_NICE not available");
|
||||
capabilities_okay = false;
|
||||
}
|
||||
if (!(data->permitted & (1 << CAP_IPC_LOCK)))
|
||||
{
|
||||
// Necessary for mmap() to work correctly
|
||||
logg("WARNING: Required Linux capability CAP_IPC_LOCK not available");
|
||||
capabilities_okay = false;
|
||||
}
|
||||
if (!(data->permitted & (1 << CAP_CHOWN)))
|
||||
{
|
||||
// Necessary for chown() to work correctly
|
||||
logg("WARNING: Required Linux capability CAP_CHOWN not available");
|
||||
capabilities_okay = false;
|
||||
}
|
||||
|
||||
// Free allocated memory
|
||||
free(hdr);
|
||||
|
||||
Reference in New Issue
Block a user