Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc-1.1
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-1.1
Commits
3f6bd266
Commit
3f6bd266
authored
Oct 15, 2008
by
Rémi Denis-Courmont
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
msg_Unsubscribe: race condition memory leak
parent
cf08617d
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
0 deletions
+9
-0
src/misc/messages.c
src/misc/messages.c
+9
-0
No files found.
src/misc/messages.c
View file @
3f6bd266
...
...
@@ -275,6 +275,15 @@ void msg_Unsubscribe (msg_subscription_t *sub)
vlc_mutex_unlock
(
&
bank
->
lock
);
vlc_join
(
sub
->
thread
,
NULL
);
/* Free dangling (not flushed) messages. */
/* NOTE: no locking, only this thread can refer to the subscription now. */
while
(
sub
->
begin
!=
sub
->
end
)
{
msg_Release
(
sub
->
items
[
sub
->
begin
]);
if
(
++
sub
->
begin
==
VLC_MSG_QSIZE
)
sub
->
begin
=
0
;
}
free
(
sub
);
}
...
...
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