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
1571438c
Commit
1571438c
authored
May 10, 2015
by
Rémi Denis-Courmont
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Android: fix potentially dangling condition variable pointer
This partially reverts commit
e9ffcf98
.
parent
30ab1259
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
14 deletions
+6
-14
src/android/thread.c
src/android/thread.c
+6
-14
No files found.
src/android/thread.c
View file @
1571438c
...
@@ -255,13 +255,9 @@ void vlc_cond_wait (vlc_cond_t *condvar, vlc_mutex_t *p_mutex)
...
@@ -255,13 +255,9 @@ void vlc_cond_wait (vlc_cond_t *condvar, vlc_mutex_t *p_mutex)
if
(
th
!=
NULL
)
if
(
th
!=
NULL
)
{
{
if
(
vlc_mutex_trylock
(
&
th
->
lock
)
==
0
)
vlc_mutex_lock
(
&
th
->
lock
);
{
th
->
cond
=
NULL
;
thread
->
cond
=
NULL
;
vlc_mutex_unlock
(
&
th
->
lock
);
vlc_mutex_unlock
(
&
th
->
lock
);
}
/* Else: This thread was cancelled and is cancellable.
vlc_testcancel() will take of it right there: */
vlc_testcancel
();
vlc_testcancel
();
}
}
}
}
...
@@ -316,13 +312,9 @@ int vlc_cond_timedwait (vlc_cond_t *condvar, vlc_mutex_t *p_mutex,
...
@@ -316,13 +312,9 @@ int vlc_cond_timedwait (vlc_cond_t *condvar, vlc_mutex_t *p_mutex,
if
(
th
!=
NULL
)
if
(
th
!=
NULL
)
{
{
if
(
vlc_mutex_trylock
(
&
th
->
lock
)
==
0
)
vlc_mutex_lock
(
&
th
->
lock
);
{
th
->
cond
=
NULL
;
thread
->
cond
=
NULL
;
vlc_mutex_unlock
(
&
th
->
lock
);
vlc_mutex_unlock
(
&
th
->
lock
);
}
/* Else: This thread was cancelled and is cancellable.
vlc_testcancel() will take of it right there: */
vlc_testcancel
();
vlc_testcancel
();
}
}
return
val
;
return
val
;
...
...
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