mirror of
https://gitlab.freedesktop.org/wayland/wayland.git
synced 2025-10-29 05:40:16 -04:00
client: simplify create_proxies() loop
Decrease the indentation a bit. No functional change. Signed-off-by: Simon Ser <contact@emersion.fr>
This commit is contained in:
parent
7a1e7dd549
commit
440defbd2b
1 changed files with 12 additions and 15 deletions
|
|
@ -1487,22 +1487,19 @@ create_proxies(struct wl_proxy *sender, struct wl_closure *closure)
|
||||||
count = arg_count_for_signature(signature);
|
count = arg_count_for_signature(signature);
|
||||||
for (i = 0; i < count; i++) {
|
for (i = 0; i < count; i++) {
|
||||||
signature = get_next_argument(signature, &arg);
|
signature = get_next_argument(signature, &arg);
|
||||||
switch (arg.type) {
|
if (arg.type != WL_ARG_NEW_ID)
|
||||||
case WL_ARG_NEW_ID:
|
continue;
|
||||||
id = closure->args[i].n;
|
|
||||||
if (id == 0) {
|
id = closure->args[i].n;
|
||||||
closure->args[i].o = NULL;
|
if (id == 0) {
|
||||||
break;
|
closure->args[i].o = NULL;
|
||||||
}
|
continue;
|
||||||
proxy = wl_proxy_create_for_id(sender, id,
|
|
||||||
closure->message->types[i]);
|
|
||||||
if (proxy == NULL)
|
|
||||||
return -1;
|
|
||||||
closure->args[i].o = (struct wl_object *)proxy;
|
|
||||||
break;
|
|
||||||
default:
|
|
||||||
break;
|
|
||||||
}
|
}
|
||||||
|
proxy = wl_proxy_create_for_id(sender, id,
|
||||||
|
closure->message->types[i]);
|
||||||
|
if (proxy == NULL)
|
||||||
|
return -1;
|
||||||
|
closure->args[i].o = (struct wl_object *)proxy;
|
||||||
}
|
}
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue