mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-01-12 02:15:31 +00:00
Cast away const from GstMetaInfo in *_get_meta_info() functions
MSVC warns about the const in the implicit argument conversion in the calls to g_once_init_{enter,leave}. It's OK so explicitly cast it. https://bugzilla.gnome.org/show_bug.cgi?id=774293
This commit is contained in:
parent
1e30725331
commit
075744a894
4 changed files with 9 additions and 8 deletions
|
@ -2481,7 +2481,7 @@ gst_parent_buffer_meta_get_info (void)
|
||||||
{
|
{
|
||||||
static const GstMetaInfo *meta_info = NULL;
|
static const GstMetaInfo *meta_info = NULL;
|
||||||
|
|
||||||
if (g_once_init_enter (&meta_info)) {
|
if (g_once_init_enter ((GstMetaInfo **) & meta_info)) {
|
||||||
const GstMetaInfo *meta =
|
const GstMetaInfo *meta =
|
||||||
gst_meta_register (gst_parent_buffer_meta_api_get_type (),
|
gst_meta_register (gst_parent_buffer_meta_api_get_type (),
|
||||||
"GstParentBufferMeta",
|
"GstParentBufferMeta",
|
||||||
|
@ -2489,7 +2489,7 @@ gst_parent_buffer_meta_get_info (void)
|
||||||
(GstMetaInitFunction) _gst_parent_buffer_meta_init,
|
(GstMetaInitFunction) _gst_parent_buffer_meta_init,
|
||||||
(GstMetaFreeFunction) _gst_parent_buffer_meta_free,
|
(GstMetaFreeFunction) _gst_parent_buffer_meta_free,
|
||||||
_gst_parent_buffer_meta_transform);
|
_gst_parent_buffer_meta_transform);
|
||||||
g_once_init_leave (&meta_info, meta);
|
g_once_init_leave ((GstMetaInfo **) & meta_info, (GstMetaInfo *) meta);
|
||||||
}
|
}
|
||||||
|
|
||||||
return meta_info;
|
return meta_info;
|
||||||
|
|
|
@ -111,13 +111,14 @@ gst_protection_meta_get_info (void)
|
||||||
{
|
{
|
||||||
static const GstMetaInfo *protection_meta_info = NULL;
|
static const GstMetaInfo *protection_meta_info = NULL;
|
||||||
|
|
||||||
if (g_once_init_enter (&protection_meta_info)) {
|
if (g_once_init_enter ((GstMetaInfo **) & protection_meta_info)) {
|
||||||
const GstMetaInfo *meta =
|
const GstMetaInfo *meta =
|
||||||
gst_meta_register (GST_PROTECTION_META_API_TYPE, "GstProtectionMeta",
|
gst_meta_register (GST_PROTECTION_META_API_TYPE, "GstProtectionMeta",
|
||||||
sizeof (GstProtectionMeta), gst_protection_meta_init,
|
sizeof (GstProtectionMeta), gst_protection_meta_init,
|
||||||
gst_protection_meta_free, gst_protection_meta_transform);
|
gst_protection_meta_free, gst_protection_meta_transform);
|
||||||
|
|
||||||
g_once_init_leave (&protection_meta_info, meta);
|
g_once_init_leave ((GstMetaInfo **) & protection_meta_info,
|
||||||
|
(GstMetaInfo *) meta);
|
||||||
}
|
}
|
||||||
return protection_meta_info;
|
return protection_meta_info;
|
||||||
}
|
}
|
||||||
|
|
|
@ -83,13 +83,13 @@ gst_net_address_meta_get_info (void)
|
||||||
{
|
{
|
||||||
static const GstMetaInfo *meta_info = NULL;
|
static const GstMetaInfo *meta_info = NULL;
|
||||||
|
|
||||||
if (g_once_init_enter (&meta_info)) {
|
if (g_once_init_enter ((GstMetaInfo **) & meta_info)) {
|
||||||
const GstMetaInfo *mi = gst_meta_register (GST_NET_ADDRESS_META_API_TYPE,
|
const GstMetaInfo *mi = gst_meta_register (GST_NET_ADDRESS_META_API_TYPE,
|
||||||
"GstNetAddressMeta",
|
"GstNetAddressMeta",
|
||||||
sizeof (GstNetAddressMeta),
|
sizeof (GstNetAddressMeta),
|
||||||
net_address_meta_init,
|
net_address_meta_init,
|
||||||
net_address_meta_free, net_address_meta_transform);
|
net_address_meta_free, net_address_meta_transform);
|
||||||
g_once_init_leave (&meta_info, mi);
|
g_once_init_leave ((GstMetaInfo **) & meta_info, (GstMetaInfo *) mi);
|
||||||
}
|
}
|
||||||
return meta_info;
|
return meta_info;
|
||||||
}
|
}
|
||||||
|
|
|
@ -87,7 +87,7 @@ gst_net_control_message_meta_get_info (void)
|
||||||
{
|
{
|
||||||
static const GstMetaInfo *meta_info = NULL;
|
static const GstMetaInfo *meta_info = NULL;
|
||||||
|
|
||||||
if (g_once_init_enter (&meta_info)) {
|
if (g_once_init_enter ((GstMetaInfo **) & meta_info)) {
|
||||||
const GstMetaInfo *mi =
|
const GstMetaInfo *mi =
|
||||||
gst_meta_register (GST_NET_CONTROL_MESSAGE_META_API_TYPE,
|
gst_meta_register (GST_NET_CONTROL_MESSAGE_META_API_TYPE,
|
||||||
"GstNetControlMessageMeta",
|
"GstNetControlMessageMeta",
|
||||||
|
@ -95,7 +95,7 @@ gst_net_control_message_meta_get_info (void)
|
||||||
net_control_message_meta_init,
|
net_control_message_meta_init,
|
||||||
net_control_message_meta_free,
|
net_control_message_meta_free,
|
||||||
net_control_message_meta_transform);
|
net_control_message_meta_transform);
|
||||||
g_once_init_leave (&meta_info, mi);
|
g_once_init_leave ((GstMetaInfo **) & meta_info, (GstMetaInfo *) mi);
|
||||||
}
|
}
|
||||||
return meta_info;
|
return meta_info;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue