
_cogl_material_get_layer expects a CoglMaterial* pointer but it was being called with a CoglHandle. This doesn't matter because the CoglHandle is actually just the CoglMaterial* pointer anyway but it breaks the ability to change the _cogl_material_pointer_from_handle macro.