arg-types: Properly handle const-GstCaps* return values
authorEdward Hervey <edward.hervey@collabora.co.uk>
Wed, 5 Jan 2011 14:04:25 +0000 (15:04 +0100)
committerEdward Hervey <edward.hervey@collabora.co.uk>
Wed, 5 Jan 2011 14:05:02 +0000 (15:05 +0100)
gst/arg-types.py

index de8f2c6..bf45607 100644 (file)
@@ -138,7 +138,7 @@ class GstCapsArg(ArgType):
                        copyval = 'TRUE'
                else:
                        raise RuntimeError, "write_return not implemented for %s" % ptype
-               info.codeafter.append('    return pyg_boxed_new (GST_TYPE_CAPS, ret, '+copyval+', TRUE);')
+               info.codeafter.append('    return pyg_boxed_new (GST_TYPE_CAPS, (GstCaps*) ret, '+copyval+', TRUE);')
 
 class GstIteratorArg(ArgType):
        def write_return(self, ptype, ownsreturn, info):