diff options
author | Alberto Mardegan <alberto.mardegan@canonical.com> | 2012-03-20 14:55:07 +0400 |
---|---|---|
committer | Martin Pitt <martin.pitt@ubuntu.com> | 2012-03-22 10:39:09 +0100 |
commit | d931b26ac1ee8a36c5daef933720982a3f31c116 (patch) | |
tree | 8da08f71b0223f1d4a1b9391c33a64a534d15274 | |
parent | 1b3f8b1fde2ba25592eb038341eabf6157f12c25 (diff) | |
download | pygobject-d931b26ac1ee8a36c5daef933720982a3f31c116.tar.gz |
Support marshalling GI_TYPE_TAG_INTERFACE
Marshalling of interfaces got broken with commit
7746d2188ac4933c2c9011d84525d1e62fc18953.
Also, do not abort on unsupported types, but log a critical failure and
continue.
https://bugzilla.gnome.org/show_bug.cgi?id=668903
-rw-r--r-- | gi/pygi-marshal-from-py.c | 3 | ||||
-rw-r--r-- | gi/pygi-marshal-to-py.c | 3 |
2 files changed, 4 insertions, 2 deletions
diff --git a/gi/pygi-marshal-from-py.c b/gi/pygi-marshal-from-py.c index 962747f2..c789d1d7 100644 --- a/gi/pygi-marshal-from-py.c +++ b/gi/pygi-marshal-from-py.c @@ -1066,9 +1066,10 @@ _pygi_arg_to_hash_pointer (const GIArgument *arg, return GINT_TO_POINTER(arg->v_int32); case GI_TYPE_TAG_UTF8: case GI_TYPE_TAG_FILENAME: + case GI_TYPE_TAG_INTERFACE: return arg->v_pointer; default: - g_assert_not_reached(); + g_critical("Unsupported type %s", g_type_tag_to_string(type_tag)); return arg->v_pointer; } } diff --git a/gi/pygi-marshal-to-py.c b/gi/pygi-marshal-to-py.c index ce932575..3af443de 100644 --- a/gi/pygi-marshal-to-py.c +++ b/gi/pygi-marshal-to-py.c @@ -521,9 +521,10 @@ _pygi_hash_pointer_to_arg (GIArgument *arg, break; case GI_TYPE_TAG_UTF8: case GI_TYPE_TAG_FILENAME: + case GI_TYPE_TAG_INTERFACE: break; default: - g_assert_not_reached(); + g_critical("Unsupported type %s", g_type_tag_to_string(type_tag)); } } |