mirror of
https://github.com/bol-van/zapret.git
synced 2025-04-19 21:42:59 +03:00
tpws,nfqws : fix checkpcap
This commit is contained in:
parent
c69a31cc1d
commit
12c6c90d47
@ -12,7 +12,7 @@ bool checkpcap(uint64_t caps)
|
|||||||
uint32_t c0 = (uint32_t)caps;
|
uint32_t c0 = (uint32_t)caps;
|
||||||
uint32_t c1 = (uint32_t)(caps>>32);
|
uint32_t c1 = (uint32_t)(caps>>32);
|
||||||
|
|
||||||
return !capget(&ch,cd) && (cd[0].effective & c0)==c0 && (cd[0].effective & c1)==c1;
|
return !capget(&ch,cd) && (cd[0].effective & c0)==c0 && (cd[1].effective & c1)==c1;
|
||||||
}
|
}
|
||||||
bool setpcap(uint64_t caps)
|
bool setpcap(uint64_t caps)
|
||||||
{
|
{
|
||||||
|
@ -12,7 +12,7 @@ bool checkpcap(uint64_t caps)
|
|||||||
uint32_t c0 = (uint32_t)caps;
|
uint32_t c0 = (uint32_t)caps;
|
||||||
uint32_t c1 = (uint32_t)(caps>>32);
|
uint32_t c1 = (uint32_t)(caps>>32);
|
||||||
|
|
||||||
return !capget(&ch,cd) && (cd[0].effective & c0)==c0 && (cd[0].effective & c1)==c1;
|
return !capget(&ch,cd) && (cd[0].effective & c0)==c0 && (cd[1].effective & c1)==c1;
|
||||||
}
|
}
|
||||||
bool setpcap(uint64_t caps)
|
bool setpcap(uint64_t caps)
|
||||||
{
|
{
|
||||||
|
Loading…
x
Reference in New Issue
Block a user