Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

net: sockets: services: Don't modify pollfd array from other threads #75525

Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 0 additions & 5 deletions subsys/net/lib/sockets/sockets_service.c
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,6 @@ void net_socket_service_foreach(net_socket_service_cb_t cb, void *user_data)
static void cleanup_svc_events(const struct net_socket_service_desc *svc)
{
for (int i = 0; i < svc->pev_len; i++) {
ctx.events[get_idx(svc) + i].fd = -1;
svc->pev[i].event.fd = -1;
svc->pev[i].event.events = 0;
}
Expand Down Expand Up @@ -87,10 +86,6 @@ int z_impl_net_socket_service_register(const struct net_socket_service_desc *svc
svc->pev[i].event = fds[i];
svc->pev[i].user_data = user_data;
}

for (i = 0; i < svc->pev_len; i++) {
ctx.events[get_idx(svc) + i] = svc->pev[i].event;
}
}

/* Tell the thread to re-read the variables */
Expand Down
Loading