Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc-gpu
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-gpu
Commits
3bb6e111
Commit
3bb6e111
authored
Apr 03, 2010
by
Erwan Tulou
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
net: fix socket blocking if accept4 not available
same options needed for vlc_accept as those for vlc_socket
parent
186273ab
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
1 deletion
+11
-1
src/text/filesystem.c
src/text/filesystem.c
+11
-1
No files found.
src/text/filesystem.c
View file @
3bb6e111
...
...
@@ -636,7 +636,7 @@ int vlc_socket (int pf, int type, int proto, bool nonblock)
type
|=
SOCK_CLOEXEC
;
if
(
nonblock
)
type
|=
SOCK_NONBLOCK
;
fd
=
socket
(
pf
,
type
|
SOCK_NONBLOCK
|
SOCK_CLOEXEC
,
proto
);
fd
=
socket
(
pf
,
type
,
proto
);
if
(
fd
!=
-
1
||
errno
!=
EINVAL
)
return
fd
;
...
...
@@ -693,7 +693,17 @@ int vlc_accept (int lfd, struct sockaddr *addr, socklen_t *alen, bool nonblock)
{
int
fd
=
accept
(
lfd
,
addr
,
alen
);
if
(
fd
!=
-
1
)
{
#ifndef WIN32
fcntl
(
fd
,
F_SETFD
,
FD_CLOEXEC
);
if
(
nonblock
)
fcntl
(
fd
,
F_SETFL
,
fcntl
(
fd
,
F_GETFL
,
0
)
|
O_NONBLOCK
);
#else
if
(
nonblock
)
ioctlsocket
(
fd
,
FIONBIO
,
&
(
unsigned
long
){
1
});
#endif
return
fd
;
}
}
while
(
errno
==
EINTR
);
...
...
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