mirror of
https://gitlab.freedesktop.org/wayland/wayland.git
synced 2025-11-01 22:58:40 -04:00
scanner: Fail if there's a 'destroy' request not marked as a destructor
This commit is contained in:
parent
c72ebf5df9
commit
a9ac0eb249
1 changed files with 3 additions and 0 deletions
|
|
@ -217,6 +217,9 @@ start_element(void *data, const char *element_name, const char **atts)
|
|||
else
|
||||
message->destructor = 0;
|
||||
|
||||
if (strcmp(name, "destroy") == 0 && !message->destructor)
|
||||
fail(ctx, "destroy request should be destructor type");
|
||||
|
||||
ctx->message = message;
|
||||
} else if (strcmp(element_name, "arg") == 0) {
|
||||
arg = malloc(sizeof *arg);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue