wlr_xdg_toplevel_icon_v1: check the correct resource

Signed-off-by: xurui <xurui@kylinos.cn>
This commit is contained in:
xurui 2025-08-27 20:01:50 +08:00
parent b0c886ec77
commit 7bf5ff4c02

View file

@ -153,7 +153,7 @@ static void manager_handle_create_icon(struct wl_client *client, struct wl_resou
struct wl_resource *icon_resource = wl_resource_create(client, struct wl_resource *icon_resource = wl_resource_create(client,
&xdg_toplevel_icon_v1_interface, wl_resource_get_version(resource), id); &xdg_toplevel_icon_v1_interface, wl_resource_get_version(resource), id);
if (resource == NULL) { if (icon_resource == NULL) {
wl_client_post_no_memory(client); wl_client_post_no_memory(client);
free(icon); free(icon);
return; return;