mirror of
https://github.com/swaywm/sway.git
synced 2025-11-05 13:29:51 -05:00
Cleanup list code
This commit is contained in:
parent
19e831ed3d
commit
c8776fac42
11 changed files with 17 additions and 37 deletions
|
|
@ -73,14 +73,11 @@ static void handle_display_destroy(struct wl_listener *listener, void *data) {
|
|||
unlink(ipc_sockaddr->sun_path);
|
||||
|
||||
while (ipc_client_list->length) {
|
||||
struct ipc_client *client = ipc_client_list->items[0];
|
||||
ipc_client_disconnect(client);
|
||||
ipc_client_disconnect(ipc_client_list->items[ipc_client_list->length-1]);
|
||||
}
|
||||
list_free(ipc_client_list);
|
||||
|
||||
if (ipc_sockaddr) {
|
||||
free(ipc_sockaddr);
|
||||
}
|
||||
free(ipc_sockaddr);
|
||||
|
||||
wl_list_remove(&ipc_display_destroy.link);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue