mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-07-30 13:53:30 +02:00
gobject: Use g_memdup2() instead of g_memdup() in obvious places
Convert all the call sites which use `g_memdup()`’s length argument trivially (for example, by passing a `sizeof()`), so that they use `g_memdup2()` instead. In almost all of these cases the use of `g_memdup()` would not have caused problems, but it will soon be deprecated, so best port away from it. Signed-off-by: Philip Withnall <pwithnall@endlessos.org> Helps: #2319
This commit is contained in:
@@ -1797,7 +1797,7 @@ g_signal_newv (const gchar *signal_name,
|
||||
node->single_va_closure_is_valid = FALSE;
|
||||
node->flags = signal_flags & G_SIGNAL_FLAGS_MASK;
|
||||
node->n_params = n_params;
|
||||
node->param_types = g_memdup (param_types, sizeof (GType) * n_params);
|
||||
node->param_types = g_memdup2 (param_types, sizeof (GType) * n_params);
|
||||
node->return_type = return_type;
|
||||
node->class_closure_bsa = NULL;
|
||||
if (accumulator)
|
||||
|
Reference in New Issue
Block a user