mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2024-11-09 19:06:15 +01:00
Merge branch 'static_analysis_2_40_patches' into 'master'
Static analysis 2 40 patches Closes #905 See merge request GNOME/glib!1042
This commit is contained in:
commit
c178c9734c
@ -476,7 +476,10 @@ end_element (GMarkupParseContext *context,
|
||||
g_set_error (error, G_MARKUP_ERROR, G_MARKUP_ERROR_INVALID_CONTENT,
|
||||
_("Error compressing file %s"),
|
||||
real_file);
|
||||
goto cleanup;
|
||||
g_object_unref (compressor);
|
||||
g_object_unref (out);
|
||||
g_object_unref (out2);
|
||||
goto cleanup;
|
||||
}
|
||||
|
||||
g_free (data->content);
|
||||
|
@ -392,7 +392,7 @@ read_netlink_messages (GNetworkMonitorNetlink *nl,
|
||||
if (!nl->priv->dump_networks &&
|
||||
rtmsg->rtm_family == AF_INET6 &&
|
||||
rtmsg->rtm_dst_len != 0 &&
|
||||
UNALIGNED_IN6_IS_ADDR_MC_LINKLOCAL (dest))
|
||||
(dest && UNALIGNED_IN6_IS_ADDR_MC_LINKLOCAL (dest)))
|
||||
continue;
|
||||
|
||||
if (msg->nlmsg_type == RTM_NEWROUTE)
|
||||
|
@ -1829,9 +1829,10 @@ platform_get_argv0 (void)
|
||||
&len,
|
||||
NULL))
|
||||
return NULL;
|
||||
|
||||
/* Sanity check for a NUL terminator. */
|
||||
if (!memchr (cmdline, 0, len))
|
||||
return NULL;
|
||||
g_assert (memchr (cmdline, 0, len));
|
||||
|
||||
/* We could just return cmdline, but I think it's better
|
||||
* to hold on to a smaller malloc block; the arguments
|
||||
* could be large.
|
||||
|
@ -1729,7 +1729,7 @@ g_object_new_with_custom_constructor (GObjectClass *class,
|
||||
break;
|
||||
}
|
||||
|
||||
if (j == n_params)
|
||||
if (value == NULL)
|
||||
{
|
||||
value = &cvalues[cvals_used++];
|
||||
g_value_init (value, pspec->value_type);
|
||||
@ -1855,7 +1855,7 @@ g_object_new_internal (GObjectClass *class,
|
||||
break;
|
||||
}
|
||||
|
||||
if (j == n_params)
|
||||
if (value == NULL)
|
||||
value = g_param_spec_get_default_value (pspec);
|
||||
|
||||
object_set_property (object, pspec, value, nqueue);
|
||||
|
Loading…
Reference in New Issue
Block a user