From 80f92e0a20d49f6965a057b95b0a1e0ba61f1e98 Mon Sep 17 00:00:00 2001 From: Sebastian Keller Date: Sun, 10 Nov 2024 01:50:03 +0100 Subject: [PATCH] cogl/boxed-value: Set size on initialization Since 1eba07f6 the size of a boxed value is read when calling _cogl_boxed_value_set_x(). This results in an uninitialized read when setting uniforms using cogl_pipeline_set_uniform_*() since the size was not initialized by _cogl_pipeline_override_uniform() when these functions call _cogl_boxed_value_set_*(). Part-of: --- cogl/cogl/cogl-boxed-value.h | 1 + 1 file changed, 1 insertion(+) diff --git a/cogl/cogl/cogl-boxed-value.h b/cogl/cogl/cogl-boxed-value.h index 0a03bd0e4..0bf8d703d 100644 --- a/cogl/cogl/cogl-boxed-value.h +++ b/cogl/cogl/cogl-boxed-value.h @@ -61,6 +61,7 @@ typedef struct _CoglBoxedValue CoglBoxedValue *_bv = (bv); \ _bv->type = COGL_BOXED_NONE; \ _bv->count = 1; \ + _bv->size = 0; \ } G_STMT_END char *