net: websockets: Fix ZFD_IOCTL_SET_LOCK handling
The websocket "socket" layer did not handle ZFD_IOCTL_SET_LOCK command,
and just forwarded it to the underlying socket. This overwritten the
mutex pointer used by the underlying socket, resulting in erroneous
behaviour in certain cases.
@@ -505,6 +505,10 @@ static int websocket_ioctl_vmeth(void *obj, unsigned int request, va_list args)
return websocket_poll_offload(fds, nfds, timeout);
}
+ case ZFD_IOCTL_SET_LOCK:
+ /* Ignore, don't want to overwrite underlying socket lock. */
+ return 0;
+
default: {
const struct fd_op_vtable *vtable;
void *core_obj;
