ref: 5a668f4ac1852bf92f3f0f7339bfec2db6db6175
parent: 464b83a87fb9d1841de5f619db8a515161bbbbce
author: Noam Preil <noam@pixelhero.dev>
date: Tue Jun 1 21:20:58 EDT 2021
fix empty page handling
--- a/main.c
+++ b/main.c
@@ -20,7 +20,7 @@
{
Page p;
pageinit(&p);
- if(pagerender(&p, page))
+ if(pagerender(&p, page) && p.buf.sz != 0)
write(1, p.buf.b, p.buf.sz);
pagefree(&p);
}