GtkShaderBuilder Fix copy/paste error in precondition

gtk_shader_builder_add_define should check both define_name and
define_value for not-NULL and not-empty, but the second precondition
check checks define_name again for not-empty-ness.
This commit is contained in:
Timm Bäder 2017-03-16 19:16:24 +01:00
parent 1fe4b13871
commit 242368bdf6

View File

@ -147,7 +147,7 @@ gsk_shader_builder_add_define (GskShaderBuilder *builder,
{
g_return_if_fail (GSK_IS_SHADER_BUILDER (builder));
g_return_if_fail (define_name != NULL && *define_name != '\0');
g_return_if_fail (define_value != NULL && *define_name != '\0');
g_return_if_fail (define_value != NULL && *define_value != '\0');
g_ptr_array_add (builder->defines, g_strdup (define_name));
g_ptr_array_add (builder->defines, g_strdup (define_value));