[gtk/wip/chergert/glproto] add check for valid entry size



commit 554a16d563ebffff373a75ec8ef5ccd25eac8d38
Author: Christian Hergert <chergert redhat com>
Date:   Wed Jan 20 12:43:23 2021 -0800

    add check for valid entry size

 gsk/next/gskgltexturelibraryprivate.h | 1 +
 1 file changed, 1 insertion(+)
---
diff --git a/gsk/next/gskgltexturelibraryprivate.h b/gsk/next/gskgltexturelibraryprivate.h
index 52aefd469f..8075d7fcd9 100644
--- a/gsk/next/gskgltexturelibraryprivate.h
+++ b/gsk/next/gskgltexturelibraryprivate.h
@@ -188,6 +188,7 @@ gsk_gl_texture_library_can_cache (GskGLTextureLibrary *self,
                                   int                  width,
                                   int                  height)
 {
+  g_assert (self->max_entry_size > 0);
   return width <= self->max_entry_size && height <= self->max_entry_size;
 }
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]