mirror of
https://github.com/RGBCube/serenity
synced 2025-07-26 19:37:36 +00:00
IPv4: Require "inet" promise for ioctl() on an IPv4Socket
This commit is contained in:
parent
a27d2b7b32
commit
35c84504cd
1 changed files with 1 additions and 0 deletions
|
@ -435,6 +435,7 @@ KResult IPv4Socket::getsockopt(FileDescription& description, int level, int opti
|
||||||
|
|
||||||
int IPv4Socket::ioctl(FileDescription&, unsigned request, unsigned arg)
|
int IPv4Socket::ioctl(FileDescription&, unsigned request, unsigned arg)
|
||||||
{
|
{
|
||||||
|
REQUIRE_PROMISE(inet);
|
||||||
auto* ifr = (ifreq*)arg;
|
auto* ifr = (ifreq*)arg;
|
||||||
if (!current->process().validate_read_typed(ifr))
|
if (!current->process().validate_read_typed(ifr))
|
||||||
return -EFAULT;
|
return -EFAULT;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue