79325343

Date: 2025-01-03 02:09:58
Score: 2
Natty:
Report link

According to what mentioned by @Botje, using a std::unique_ptr to GstPad as a private member is actually wrong design here. The issue is that while the sink_pad in the callback is released at the end of the function, the parameter new_pad is not. That's indicates that not all the GstPad* own the object it points to. Thus using std::unique_ptr in this context is inappropriate.

Reasons:
  • Has code block (-0.5):
  • User mentioned (1): @Botje
  • Self-answer (0.5):
  • Single line (0.5):
  • Low reputation (0.5):
Posted by: iEcho-42