Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc
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
Commits
4d799ee3
Commit
4d799ee3
authored
Aug 17, 2008
by
Rémi Denis-Courmont
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Join the input thread before we destroy the input object
parent
c8ef90d5
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
16 additions
and
11 deletions
+16
-11
src/input/vlm.c
src/input/vlm.c
+15
-11
src/playlist/engine.c
src/playlist/engine.c
+1
-0
No files found.
src/input/vlm.c
View file @
4d799ee3
...
...
@@ -759,11 +759,13 @@ static vlm_media_instance_sys_t *vlm_MediaInstanceNew( vlm_t *p_vlm, const char
}
static
void
vlm_MediaInstanceDelete
(
vlm_media_instance_sys_t
*
p_instance
)
{
if
(
p_instance
->
p_input
)
input_thread_t
*
p_input
=
p_instance
->
p_input
;
if
(
p_input
)
{
input_StopThread
(
p_instance
->
p_input
);
p_instance
->
p_sout
=
input_DetachSout
(
p_instance
->
p_input
);
vlc_object_release
(
p_instance
->
p_input
);
input_StopThread
(
p_input
);
p_instance
->
p_sout
=
input_DetachSout
(
p_input
);
vlc_thread_join
(
p_input
);
vlc_object_release
(
p_input
);
}
if
(
p_instance
->
p_sout
)
sout_DeleteInstance
(
p_instance
->
p_sout
);
...
...
@@ -827,19 +829,21 @@ static int vlm_ControlMediaInstanceStart( vlm_t *p_vlm, int64_t id, const char *
}
/* Stop old instance */
if
(
p_instance
->
p_input
)
input_thread_t
*
p_input
=
p_instance
->
p_input
;
if
(
p_input
)
{
if
(
p_instance
->
i_index
==
i_input_index
&&
!
p_in
stance
->
p_input
->
b_eof
&&
!
p_instance
->
p_input
->
b_error
)
!
p_in
put
->
b_eof
&&
!
p_input
->
b_error
)
{
if
(
var_GetInteger
(
p_in
stance
->
p_in
put
,
"state"
)
==
PAUSE_S
)
var_SetInteger
(
p_in
stance
->
p_in
put
,
"state"
,
PLAYING_S
);
if
(
var_GetInteger
(
p_input
,
"state"
)
==
PAUSE_S
)
var_SetInteger
(
p_input
,
"state"
,
PLAYING_S
);
return
VLC_SUCCESS
;
}
input_StopThread
(
p_instance
->
p_input
);
p_instance
->
p_sout
=
input_DetachSout
(
p_instance
->
p_input
);
vlc_object_release
(
p_instance
->
p_input
);
input_StopThread
(
p_input
);
p_instance
->
p_sout
=
input_DetachSout
(
p_input
);
vlc_thread_join
(
p_input
);
vlc_object_release
(
p_input
);
if
(
!
p_instance
->
b_sout_keep
&&
p_instance
->
p_sout
)
{
sout_DeleteInstance
(
p_instance
->
p_sout
);
...
...
src/playlist/engine.c
View file @
4d799ee3
...
...
@@ -241,6 +241,7 @@ void playlist_release_current_input( playlist_t * p_playlist )
/* Release the playlist lock, because we may get stuck
* in vlc_object_release() for some time. */
PL_UNLOCK
;
vlc_thread_join
(
p_input
);
vlc_object_release
(
p_input
);
PL_LOCK
;
}
...
...
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