-
Mike Gorse authored
It is not safe to ref a hash marked (transfer none) and expect its elements to remain, since the caller will assume that it owns the elements and may deallocate them (this is done by pygobject). It would also be problematic to simply mark the hash (transfer full), since we need to either assume that the caller passed a destroy function when creating the hash (pygobject does not) or deallocate the values ourselves when the match rule is finalized (which requires making assumptions about the correct free function needed to deallocate the values that the caller allocated). So it seems that the only safe thing to do is to copy the hash.
dca58979