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
10f105d2
Commit
10f105d2
authored
Feb 14, 2010
by
Rémi Denis-Courmont
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
vlc_object_waitpipe: cancellation safety
parent
1b20e18a
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
0 deletions
+4
-0
src/misc/objects.c
src/misc/objects.c
+4
-0
No files found.
src/misc/objects.c
View file @
10f105d2
...
...
@@ -356,6 +356,9 @@ int vlc_object_waitpipe( vlc_object_t *obj )
/* This can only ever happen if someone killed us without locking: */
assert
(
internals
->
pipes
[
1
]
==
-
1
);
/* pipe() is not a cancellation point, but write() is and eventfd() is
* unspecified (not in POSIX). */
int
canc
=
vlc_savecancel
();
#if defined (HAVE_SYS_EVENTFD_H)
internals
->
pipes
[
0
]
=
internals
->
pipes
[
1
]
=
eventfd
(
0
,
EFD_CLOEXEC
);
if
(
internals
->
pipes
[
0
]
==
-
1
)
...
...
@@ -370,6 +373,7 @@ int vlc_object_waitpipe( vlc_object_t *obj )
msg_Dbg
(
obj
,
"waitpipe: object already dying"
);
write
(
internals
->
pipes
[
1
],
&
(
uint64_t
){
1
},
sizeof
(
uint64_t
));
}
vlc_restorecancel
(
canc
);
}
vlc_mutex_unlock
(
&
pipe_lock
);
return
internals
->
pipes
[
0
];
...
...
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