Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc-2-2
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-2-2
Commits
def34b91
Commit
def34b91
authored
Jun 14, 2008
by
Pierre d'Herbemont
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
playlist: de-inline p_input setters.
parent
966feba1
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
38 additions
and
30 deletions
+38
-30
src/playlist/engine.c
src/playlist/engine.c
+35
-0
src/playlist/playlist_internal.h
src/playlist/playlist_internal.h
+3
-30
No files found.
src/playlist/engine.c
View file @
def34b91
...
...
@@ -203,6 +203,41 @@ static void ObjectGarbageCollector( playlist_t *p_playlist, bool b_force )
vlc_mutex_unlock
(
&
p_playlist
->
gc_lock
);
}
/* Internals */
void
playlist_release_current_input
(
playlist_t
*
p_playlist
)
{
vlc_assert_locked
(
&
p_playlist
->
object_lock
);
if
(
!
p_playlist
->
p_input
)
return
;
input_thread_t
*
p_input
=
p_playlist
->
p_input
;
p_playlist
->
p_input
=
NULL
;
/* Release the playlist lock, because we may get stuck
* in vlc_object_release() for some time. */
PL_UNLOCK
;
vlc_object_release
(
p_input
);
PL_LOCK
;
}
void
playlist_set_current_input
(
playlist_t
*
p_playlist
,
input_thread_t
*
p_input
)
{
vlc_assert_locked
(
&
p_playlist
->
object_lock
);
playlist_release_current_input
(
p_playlist
);
if
(
p_input
)
{
vlc_object_yield
(
p_input
);
p_playlist
->
p_input
=
p_input
;
}
}
/**
* @}
*/
/**
* Main loop
*
...
...
src/playlist/playlist_internal.h
View file @
def34b91
...
...
@@ -110,36 +110,9 @@ playlist_item_t *playlist_ItemFindFromInputAndRoot( playlist_t *p_playlist,
int
playlist_DeleteFromItemId
(
playlist_t
*
,
int
);
int
playlist_ItemDelete
(
playlist_item_t
*
);
static
inline
void
playlist_release_current_input
(
playlist_t
*
p_playlist
)
{
vlc_assert_locked
(
&
p_playlist
->
object_lock
);
if
(
!
p_playlist
->
p_input
)
return
;
input_thread_t
*
p_input
=
p_playlist
->
p_input
;
p_playlist
->
p_input
=
NULL
;
/* Release the playlist lock, because we may get stuck
* in vlc_object_release() for some time. */
PL_UNLOCK
;
vlc_object_release
(
p_input
);
PL_LOCK
;
}
static
inline
void
playlist_set_current_input
(
playlist_t
*
p_playlist
,
input_thread_t
*
p_input
)
{
vlc_assert_locked
(
&
p_playlist
->
object_lock
);
playlist_release_current_input
(
p_playlist
);
if
(
p_input
)
{
vlc_object_yield
(
p_input
);
p_playlist
->
p_input
=
p_input
;
}
}
void
playlist_release_current_input
(
playlist_t
*
p_playlist
);
void
playlist_set_current_input
(
playlist_t
*
p_playlist
,
input_thread_t
*
p_input
);
/**
* @}
...
...
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