mirror of
https://github.com/swaywm/sway.git
synced 2026-03-21 05:33:56 -04:00
common/pango: log on get_text_size()/render_text() format failure
This commit is contained in:
parent
2c2a2ec380
commit
9d0dbe66c3
1 changed files with 2 additions and 0 deletions
|
|
@ -91,6 +91,7 @@ void get_text_size(cairo_t *cairo, const PangoFontDescription *desc, int *width,
|
|||
char *buf = vformat_str(fmt, args);
|
||||
va_end(args);
|
||||
if (buf == NULL) {
|
||||
sway_log(SWAY_ERROR, "Failed to format string");
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
@ -127,6 +128,7 @@ void render_text(cairo_t *cairo, const PangoFontDescription *desc,
|
|||
char *buf = vformat_str(fmt, args);
|
||||
va_end(args);
|
||||
if (buf == NULL) {
|
||||
sway_log(SWAY_ERROR, "Failed to format string");
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue