mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-02-28 13:12:10 +01:00
Don't use nested scope local variable for error
svn path=/trunk/; revision=864
This commit is contained in:
parent
65b8727e57
commit
b918bb5e8c
@ -163,7 +163,8 @@ g_function_info_invoke (GIFunctionInfo *info,
|
|||||||
gint n_args, n_invoke_args, in_pos, out_pos, i;
|
gint n_args, n_invoke_args, in_pos, out_pos, i;
|
||||||
gpointer *args;
|
gpointer *args;
|
||||||
gboolean success = FALSE;
|
gboolean success = FALSE;
|
||||||
GError *local_error;
|
GError *local_error = NULL;
|
||||||
|
gpointer error_address = &local_error;
|
||||||
|
|
||||||
symbol = g_function_info_get_symbol (info);
|
symbol = g_function_info_get_symbol (info);
|
||||||
|
|
||||||
@ -288,11 +289,9 @@ g_function_info_invoke (GIFunctionInfo *info,
|
|||||||
g_base_info_unref ((GIBaseInfo *)ainfo);
|
g_base_info_unref ((GIBaseInfo *)ainfo);
|
||||||
}
|
}
|
||||||
|
|
||||||
local_error = NULL;
|
|
||||||
if (throws)
|
if (throws)
|
||||||
{
|
{
|
||||||
gpointer address = &local_error;
|
args[n_invoke_args - 1] = &error_address;
|
||||||
args[n_invoke_args - 1] = &address;
|
|
||||||
atypes[n_invoke_args - 1] = &ffi_type_pointer;
|
atypes[n_invoke_args - 1] = &ffi_type_pointer;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user