After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 639555 - [audioparsers] Be careful to not lose the event ref
[audioparsers] Be careful to not lose the event ref
Status: RESOLVED FIXED
Product: GStreamer
Classification: Platform
Component: gst-plugins-bad
unspecified
Other All
: Normal normal
: 0.10.21
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Blocks:
 
 
Reported: 2011-01-14 19:37 UTC by Thiago Sousa Santos
Modified: 2011-01-15 16:51 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
audioparsers: baseparse: Be careful to not lose the event ref (1.12 KB, patch)
2011-01-14 19:37 UTC, Thiago Sousa Santos
accepted-commit_now Details | Review
audioparsers: baseparse: Be careful to not lose the event ref (1.72 KB, patch)
2011-01-15 16:49 UTC, Thiago Sousa Santos
committed Details | Review

Description Thiago Sousa Santos 2011-01-14 19:37:17 UTC
When handling an event, only unref if it has been handled.
Comment 1 Thiago Sousa Santos 2011-01-14 19:37:26 UTC
Created attachment 178345 [details] [review]
audioparsers: baseparse: Be careful to not lose the event ref

Only unref the event if it has been handled.
Comment 2 Tim-Philipp Müller 2011-01-14 21:16:27 UTC
Comment on attachment 178345 [details] [review]
audioparsers: baseparse: Be careful to not lose the event ref

> audioparsers: baseparse: Be careful to not lose the event ref
> 
> Only unref the event if it has been handled.

I think something like this would be clearer: "Don't unref event if it hasn't been handled, because the caller will assume it's still valid and can be re-used in that case. Fixes issue with xyz", or somesuch.

(The comment above the function should probably also mention the unusual calling semantics.)
Comment 3 Thiago Sousa Santos 2011-01-15 16:49:01 UTC
Created attachment 178395 [details] [review]
audioparsers: baseparse: Be careful to not lose the event ref

Updated patch
Comment 4 Thiago Sousa Santos 2011-01-15 16:50:36 UTC
Comment on attachment 178395 [details] [review]
audioparsers: baseparse: Be careful to not lose the event ref

Pushed with the required modifications
Comment 5 Thiago Sousa Santos 2011-01-15 16:51:43 UTC
Fix pushed as a6a982e8be06a861e23b377d8df4e3be8538ca53