提交 80f77282 编写于 作者: B Behdad Esfahbod

[util] Fix ansi output when surface is empty

上级 15685299
......@@ -63,10 +63,10 @@ helper_cairo_surface_write_to_ansi_stream (cairo_surface_t *surface,
* Find the tight image top/bottom and only print in between. */
/* Use corner color as background color. */
uint32_t bg_color = * (uint32_t *) data;
uint32_t bg_color = data ? * (uint32_t *) data : 0;
/* Drop first row while empty */
while (height)
while (height)
{
unsigned int i;
for (i = 0; i < width; i++)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册