videofilter: Should probably not change class property in set_caps()
@ndufresne
Submitted by Nicolas Dufresne Link to original bug (#791423)
Description
Just stumbled across some code that does not seem quite safe:
gst_video_filter_set_caps():
- if (fclass->transform_frame_ip == NULL)
-
GST_BASE_TRANSFORM_CLASS (fclass)->transform_ip_on_passthrough = FALSE;
This type of code is normally placed in a class init function I believe. I do expect a class to be generally immutable (except maybe for aa thread safe singleton). At least, I don't think it would be good practice to change the function pointer dynamically in an instance, or change these kind of property.