"\t(*rfunc)((%s *)object", s, s, typebase);
} else {
const char *retcast = get_cast(m->gtktypes->data, FALSE);
+ gboolean is_none = (strcmp(m->gtktypes->next->data, "NONE")==0);
out_printf(out,
"\t___%s rfunc;\n\t"
"%s *retval;\n\n"
"\trfunc = (___%s)func;\n\n"
"\tretval = GTK_RETLOC_%s(args[%d]);\n\n"
"\t*retval = (*rfunc)((%s *)object",
- s, retcast, s, (char *)m->gtktypes->data,
- g_list_length(m->gtktypes)-1, typebase);
+ s, retcast, s,
+ (char *)m->gtktypes->data,
+ g_list_length(m->gtktypes) - (is_none ? 2 : 1),
+ typebase);
}
print_signal_marsal_args(m);