mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-01-29 18:48:44 +00:00
playbin: avoid possible deference of null pointer
For safety, check the pointer playbin->curr_group is valid before reading parameters of the structure. CID #1291624
This commit is contained in:
parent
d1f91723be
commit
985ed4847f
1 changed files with 6 additions and 4 deletions
|
@ -5734,11 +5734,13 @@ failure:
|
|||
GstSourceGroup *curr_group;
|
||||
|
||||
curr_group = playbin->curr_group;
|
||||
if (curr_group && curr_group->active && curr_group->valid) {
|
||||
/* unlink our pads with the sink */
|
||||
deactivate_group (playbin, curr_group);
|
||||
if (curr_group) {
|
||||
if (curr_group->active && curr_group->valid) {
|
||||
/* unlink our pads with the sink */
|
||||
deactivate_group (playbin, curr_group);
|
||||
}
|
||||
curr_group->valid = FALSE;
|
||||
}
|
||||
curr_group->valid = FALSE;
|
||||
|
||||
/* Swap current and next group back */
|
||||
playbin->curr_group = playbin->next_group;
|
||||
|
|
Loading…
Reference in a new issue