From 892b814f54bfe1307288c9e64e3e2c2217341814 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Minisini?= Date: Sat, 15 Dec 2012 22:09:14 +0000 Subject: [PATCH] [GB.MEDIA] * NEW: Do not raise an error if a tag has an unsupported format. Just display a warning message. git-svn-id: svn://localhost/gambas/trunk@5439 867c0c6c-44f3-4631-809d-bfa615b0a4ec --- gb.media/src/c_media.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/gb.media/src/c_media.c b/gb.media/src/c_media.c index 47f834364..555f8e3ac 100644 --- a/gb.media/src/c_media.c +++ b/gb.media/src/c_media.c @@ -83,6 +83,7 @@ static GB_TYPE to_gambas_type(const GValue *value) return GB_T_DATE; else { + fprintf(stderr, "gb.media: warning: unsupported data type: %s\n", G_VALUE_TYPE_NAME(value)); //GB.Error("Unsupported property datatype"); return GB_T_NULL; } @@ -189,7 +190,7 @@ static void return_value(const GValue *value) } else { - fprintf(stderr, "gb.media: warning: unsupported datatype: %s\n", g_type_name(G_VALUE_TYPE(value))); + fprintf(stderr, "gb.media: warning: unsupported datatype: %s\n", G_VALUE_TYPE_NAME(value)); GB.ReturnNull(); } } @@ -324,7 +325,8 @@ BEGIN_METHOD(MediaTagList_get, GB_STRING name) type = to_gambas_type(value); if (type == GB_T_NULL) { - GB.Error("Unsupported property datatype"); + GB.ReturnNull(); + GB.ReturnConvVariant(); return; }