mirror of
https://github.com/apache/nuttx.git
synced 2026-06-02 09:38:37 +08:00
Added lock in ifr ioctl calls.
This commit is contained in:
committed by
Petro Karashchenko
parent
9cb17841d8
commit
9bc47ecdce
@@ -641,6 +641,8 @@ static int netdev_ifr_ioctl(FAR struct socket *psock, int cmd,
|
|||||||
|
|
||||||
ninfo("cmd: %d\n", cmd);
|
ninfo("cmd: %d\n", cmd);
|
||||||
|
|
||||||
|
net_lock();
|
||||||
|
|
||||||
/* Execute the command */
|
/* Execute the command */
|
||||||
|
|
||||||
switch (cmd)
|
switch (cmd)
|
||||||
@@ -1139,6 +1141,8 @@ static int netdev_ifr_ioctl(FAR struct socket *psock, int cmd,
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
net_unlock();
|
||||||
|
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user