Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc-gpu
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Redmine
Redmine
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
videolan
vlc-gpu
Commits
46a33c34
Commit
46a33c34
authored
May 26, 2009
by
Rémi Duraffort
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
gestures: fix memleak with var_Change(VLC_VAR_GETCHOICES).
parent
128bfa77
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
24 additions
and
16 deletions
+24
-16
modules/control/gestures.c
modules/control/gestures.c
+24
-16
No files found.
modules/control/gestures.c
View file @
46a33c34
...
...
@@ -306,8 +306,8 @@ static void RunIntf( intf_thread_t *p_intf )
case
GESTURE
(
UP
,
RIGHT
,
NONE
,
NONE
):
{
vlc_value_t
val
,
list
,
list2
;
int
i_count
,
i
;
vlc_value_t
val
,
list
,
list2
;
int
i_count
,
i
;
p_playlist
=
pl_Hold
(
p_intf
);
p_input
=
playlist_CurrentInput
(
p_playlist
);
...
...
@@ -316,20 +316,22 @@ static void RunIntf( intf_thread_t *p_intf )
if
(
!
p_input
)
break
;
var_Get
(
p_input
,
"audio-es"
,
&
val
);
var_Change
(
p_input
,
"audio-es"
,
VLC_VAR_GETCHOICES
,
&
list
,
&
list2
);
i_count
=
list
.
p_list
->
i_count
;
if
(
i_count
<=
1
)
{
vlc_object_release
(
p_input
);
break
;
}
for
(
i
=
0
;
i
<
i_count
;
i
++
)
{
if
(
val
.
i_int
==
list
.
p_list
->
p_values
[
i
].
i_int
)
break
;
}
var_Get
(
p_input
,
"audio-es"
,
&
val
);
var_Change
(
p_input
,
"audio-es"
,
VLC_VAR_GETCHOICES
,
&
list
,
&
list2
);
i_count
=
list
.
p_list
->
i_count
;
if
(
i_count
<=
1
)
{
var_Change
(
p_input
,
"audio-es"
,
VLC_VAR_FREELIST
,
&
list
,
&
list2
);
vlc_object_release
(
p_input
);
break
;
}
for
(
i
=
0
;
i
<
i_count
;
i
++
)
{
if
(
val
.
i_int
==
list
.
p_list
->
p_values
[
i
].
i_int
)
break
;
}
/* value of audio-es was not in choices list */
if
(
i
==
i_count
)
{
...
...
@@ -342,6 +344,8 @@ static void RunIntf( intf_thread_t *p_intf )
else
i
++
;
var_Set
(
p_input
,
"audio-es"
,
list
.
p_list
->
p_values
[
i
]
);
var_Change
(
p_input
,
"audio-es"
,
VLC_VAR_FREELIST
,
&
list
,
&
list2
);
vlc_object_release
(
p_input
);
}
break
;
...
...
@@ -365,6 +369,8 @@ static void RunIntf( intf_thread_t *p_intf )
if
(
i_count
<=
1
)
{
vlc_object_release
(
p_input
);
var_Change
(
p_input
,
"spu-es"
,
VLC_VAR_FREELIST
,
&
list
,
&
list2
);
break
;
}
for
(
i
=
0
;
i
<
i_count
;
i
++
)
...
...
@@ -386,6 +392,8 @@ static void RunIntf( intf_thread_t *p_intf )
else
i
++
;
var_Set
(
p_input
,
"spu-es"
,
list
.
p_list
->
p_values
[
i
]
);
var_Change
(
p_input
,
"spu-es"
,
VLC_VAR_FREELIST
,
&
list
,
&
list2
);
vlc_object_release
(
p_input
);
}
break
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment