summaryrefslogtreecommitdiff
path: root/gl.c
diff options
context:
space:
mode:
Diffstat (limited to 'gl.c')
-rw-r--r--gl.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/gl.c b/gl.c
index a9850cd..9a35a1f 100644
--- a/gl.c
+++ b/gl.c
@@ -222,6 +222,7 @@ static void gl_geometry_rect_border(Rect r, float border_thickness, u32 color) {
static void gl_geometry_draw(void) {
size_t ntriangles = arr_len(gl_geometry_triangles);
+ if (ntriangles == 0) return;
// convert coordinates to NDC
for (size_t i = 0; i < ntriangles; ++i) {