mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2024-11-10 11:26:16 +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;
|
||||
gpointer *args;
|
||||
gboolean success = FALSE;
|
||||
GError *local_error;
|
||||
GError *local_error = NULL;
|
||||
gpointer error_address = &local_error;
|
||||
|
||||
symbol = g_function_info_get_symbol (info);
|
||||
|
||||
@ -288,11 +289,9 @@ g_function_info_invoke (GIFunctionInfo *info,
|
||||
g_base_info_unref ((GIBaseInfo *)ainfo);
|
||||
}
|
||||
|
||||
local_error = NULL;
|
||||
if (throws)
|
||||
{
|
||||
gpointer address = &local_error;
|
||||
args[n_invoke_args - 1] = &address;
|
||||
args[n_invoke_args - 1] = &error_address;
|
||||
atypes[n_invoke_args - 1] = &ffi_type_pointer;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user