Commit 48acb361 authored by Jehan's avatar Jehan

libgimp: fix wrong assert in gimp_procedure_config_set_values().

The first property of a GimpProcedureConfig is the related
GimpProcedure. All others are the procedure arguments.

Among other things, this was breaking the calls to file_save() and
several unit tests.
parent f9c713d5
Pipeline #161882 failed with stages
in 26 minutes and 29 seconds
......@@ -252,11 +252,12 @@ gimp_procedure_config_set_values (GimpProcedureConfig *config,
gimp_procedure_get_aux_arguments (config->priv->procedure, &n_aux_args);
n_values = gimp_value_array_length (values);
g_return_if_fail (n_pspecs == n_values + n_aux_args);
/* The first property is the procedure, all others are arguments. */
g_return_if_fail (n_pspecs == n_values + n_aux_args + 1);
for (i = 0; i < n_values; i++)
{
GParamSpec *pspec = pspecs[i];
GParamSpec *pspec = pspecs[i + 1];
GValue *value = gimp_value_array_index (values, i);
g_object_set_property (G_OBJECT (config), pspec->name, value);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment