mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-12-03 23:31:12 +01:00
Make the GVariant code compile with a non-gcc compiler
In particular, tested with Microsoft Visual C 2008.
This commit is contained in:
@@ -1084,13 +1084,17 @@ const gchar *
|
||||
g_variant_get_string (GVariant *value,
|
||||
gsize *length)
|
||||
{
|
||||
gconstpointer data;
|
||||
gsize size;
|
||||
|
||||
g_return_val_if_fail (value != NULL, NULL);
|
||||
g_return_val_if_fail (
|
||||
g_variant_is_of_type (value, G_VARIANT_TYPE_STRING) ||
|
||||
g_variant_is_of_type (value, G_VARIANT_TYPE_OBJECT_PATH) ||
|
||||
g_variant_is_of_type (value, G_VARIANT_TYPE_SIGNATURE), NULL);
|
||||
gconstpointer data = g_variant_get_data (value);
|
||||
gsize size = g_variant_get_size (value);
|
||||
|
||||
data = g_variant_get_data (value);
|
||||
size = g_variant_get_size (value);
|
||||
|
||||
if (!g_variant_is_trusted (value))
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user