mirror of
https://gitlab.freedesktop.org/wayland/wayland.git
synced 2025-10-29 05:40:16 -04:00
server: expose wl_resource_post_error_vargs()
Signed-off-by: Kirill Primak <vyivel@eclair.cafe>
This commit is contained in:
parent
64248963d3
commit
65454cf7db
2 changed files with 14 additions and 2 deletions
|
|
@ -550,6 +550,10 @@ void
|
||||||
wl_resource_queue_event_array(struct wl_resource *resource,
|
wl_resource_queue_event_array(struct wl_resource *resource,
|
||||||
uint32_t opcode, union wl_argument *args);
|
uint32_t opcode, union wl_argument *args);
|
||||||
|
|
||||||
|
void
|
||||||
|
wl_resource_post_error_vargs(struct wl_resource *resource,
|
||||||
|
uint32_t code, const char *msg, va_list argp);
|
||||||
|
|
||||||
void
|
void
|
||||||
wl_resource_post_error(struct wl_resource *resource,
|
wl_resource_post_error(struct wl_resource *resource,
|
||||||
uint32_t code, const char *msg, ...) WL_PRINTF(3, 4);
|
uint32_t code, const char *msg, ...) WL_PRINTF(3, 4);
|
||||||
|
|
|
||||||
|
|
@ -288,7 +288,16 @@ wl_resource_queue_event(struct wl_resource *resource, uint32_t opcode, ...)
|
||||||
wl_resource_queue_event_array(resource, opcode, args);
|
wl_resource_queue_event_array(resource, opcode, args);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
/** Post a protocol error
|
||||||
|
*
|
||||||
|
* \param resource The resource object
|
||||||
|
* \param code The error code
|
||||||
|
* \param msg The error message format string
|
||||||
|
* \param argp The format string argument list
|
||||||
|
*
|
||||||
|
* \memberof wl_resource
|
||||||
|
*/
|
||||||
|
WL_EXPORT void
|
||||||
wl_resource_post_error_vargs(struct wl_resource *resource,
|
wl_resource_post_error_vargs(struct wl_resource *resource,
|
||||||
uint32_t code, const char *msg, va_list argp)
|
uint32_t code, const char *msg, va_list argp)
|
||||||
{
|
{
|
||||||
|
|
@ -310,7 +319,6 @@ wl_resource_post_error_vargs(struct wl_resource *resource,
|
||||||
wl_resource_post_event(client->display_resource,
|
wl_resource_post_event(client->display_resource,
|
||||||
WL_DISPLAY_ERROR, resource, code, buffer);
|
WL_DISPLAY_ERROR, resource, code, buffer);
|
||||||
client->error = true;
|
client->error = true;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/** Post a protocol error
|
/** Post a protocol error
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue