GNOME Bugzilla – Bug 769299
ogg: check return values in gst_ogg_parse_new_stream
Last modified: 2016-08-03 17:06:12 UTC
Created attachment 332346 [details] [review] patch There were two FIXME comments about checking the return values in gst_ogg_parse_new_stream. This function already returned NULL if ogg_stream_init() failed, but gst_ogg_parse_chain() didn't check and just assumed _new_stream succeeded. Submitting the patch here for comments. Maybe the ERROR messages can be improved :)
Review of attachment 332346 [details] [review]: This leaks the stream object (an existing return also does).
Created attachment 332479 [details] [review] patch that fixes original memory leak Thanks for the review Vincent. Sorry for missing the memory leak :S
Created attachment 332480 [details] [review] version 2 of patch to check return values Second version
Review of attachment 332479 [details] [review]: commit 5cab7236510f01af42452cc269b19ee2bd44687b Author: Luis de Bethencourt <luisbg@osg.samsung.com> Date: Mon Aug 1 15:52:11 2016 +0100 ogg: fix memory leak in gst_ogg_parse_new_stream Avoid leaking the stream object https://bugzilla.gnome.org/show_bug.cgi?id=769299
Review of attachment 332480 [details] [review]: commit 7ae577dc3a4c1471e08260a9619b0dc2b42e4d7f Author: Luis de Bethencourt <luisbg@osg.samsung.com> Date: Mon Aug 1 16:00:29 2016 +0100 ogg: check return values in gst_ogg_parse_new_stream Return NULL in gst_ogg_parse_new_stream when either ogg_stream_pagein() or gst_ogg_stream_setup_map() failed. https://bugzilla.gnome.org/show_bug.cgi?id=769299