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
2bb861e3
Commit
2bb861e3
authored
Mar 11, 2008
by
Rafaël Carré
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
use vlc_object_* and PL_{UN}LOCK to simplify
parent
0e86a35f
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
7 additions
and
7 deletions
+7
-7
src/playlist/control.c
src/playlist/control.c
+5
-5
src/playlist/engine.c
src/playlist/engine.c
+2
-2
No files found.
src/playlist/control.c
View file @
2bb861e3
...
...
@@ -206,7 +206,7 @@ int playlist_AskForArtEnqueue( playlist_t *p_playlist,
p
.
p_item
=
p_item
;
p
.
b_fetch_art
=
VLC_TRUE
;
vlc_
mutex_lock
(
&
p_playlist
->
p_fetcher
->
object_lock
);
vlc_
object_lock
(
p_playlist
->
p_fetcher
);
for
(
i
=
0
;
i
<
p_playlist
->
p_fetcher
->
i_waiting
&&
p_playlist
->
p_fetcher
->
p_waiting
->
b_fetch_art
==
VLC_TRUE
;
i
++
);
...
...
@@ -214,8 +214,8 @@ int playlist_AskForArtEnqueue( playlist_t *p_playlist,
INSERT_ELEM
(
p_playlist
->
p_fetcher
->
p_waiting
,
p_playlist
->
p_fetcher
->
i_waiting
,
i
,
p
);
vlc_
cond_signal
(
&
p_playlist
->
p_fetcher
->
object_wait
);
vlc_
mutex_unlock
(
&
p_playlist
->
p_fetcher
->
object_lock
);
vlc_
object_signal_unlocked
(
p_playlist
->
p_fetcher
);
vlc_
obj_unlock
(
p_playlist
->
p_fetcher
);
return
VLC_SUCCESS
;
}
...
...
@@ -513,9 +513,9 @@ int playlist_PlayItem( playlist_t *p_playlist, playlist_item_t *p_item )
}
val
.
i_int
=
p_input
->
i_id
;
vlc_mutex_unlock
(
&
p_playlist
->
object_lock
)
;
PL_UNLOCK
;
var_Set
(
p_playlist
,
"playlist-current"
,
val
);
vlc_mutex_lock
(
&
p_playlist
->
object_lock
)
;
PL_LOCK
;
return
VLC_SUCCESS
;
}
src/playlist/engine.c
View file @
2bb861e3
...
...
@@ -696,10 +696,10 @@ void playlist_FetcherLoop( playlist_fetcher_t *p_obj )
vlc_gc_decref
(
p_item
);
}
}
vlc_
mutex_lock
(
&
p_obj
->
object_lock
);
vlc_
object_lock
(
p_obj
);
i_activity
=
var_GetInteger
(
p_playlist
,
"activity"
);
if
(
i_activity
<
0
)
i_activity
=
0
;
vlc_
mutex_unlock
(
&
p_obj
->
object_lock
);
vlc_
object_unlock
(
p_obj
);
/* Sleep at least 1ms */
msleep
(
(
i_activity
+
1
)
*
1000
);
}
...
...
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