`gst_element_remove_pad()` doesn't automatically deactivate the pad, it has to be done explicitly beforehand, otherwise the pad task might be left dangling, exposed to undefined behaviour. Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3653>