Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
mpd
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Иван Мажукин
mpd
Commits
9ff47177
Commit
9ff47177
authored
Aug 10, 2017
by
Max Kellermann
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
system/fd_util: remove unused function accept_cloexec_nonblock()
parent
0c174098
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
0 additions
and
36 deletions
+0
-36
fd_util.c
src/system/fd_util.c
+0
-28
fd_util.h
src/system/fd_util.h
+0
-8
No files found.
src/system/fd_util.c
View file @
9ff47177
...
...
@@ -129,34 +129,6 @@ pipe_cloexec_nonblock(int fd[2])
}
int
accept_cloexec_nonblock
(
int
fd
,
struct
sockaddr
*
address
,
size_t
*
address_length_r
)
{
int
ret
;
socklen_t
address_length
=
*
address_length_r
;
#ifdef HAVE_ACCEPT4
ret
=
accept4
(
fd
,
address
,
&
address_length
,
SOCK_CLOEXEC
|
SOCK_NONBLOCK
);
if
(
ret
>=
0
||
errno
!=
ENOSYS
)
{
if
(
ret
>=
0
)
*
address_length_r
=
address_length
;
return
ret
;
}
#endif
ret
=
accept
(
fd
,
address
,
&
address_length
);
if
(
ret
>=
0
)
{
fd_set_cloexec
(
ret
,
true
);
fd_set_nonblock
(
ret
);
*
address_length_r
=
address_length
;
}
return
ret
;
}
int
close_socket
(
int
fd
)
{
#ifdef WIN32
...
...
src/system/fd_util.h
View file @
9ff47177
...
...
@@ -65,14 +65,6 @@ int
pipe_cloexec_nonblock
(
int
fd
[
2
]);
/**
* Wrapper for accept(), which sets the CLOEXEC and the NONBLOCK flags
* (atomically if supported by the OS).
*/
int
accept_cloexec_nonblock
(
int
fd
,
struct
sockaddr
*
address
,
size_t
*
address_length_r
);
/**
* Portable wrapper for close(); use closesocket() on WIN32/WinSock.
*/
int
...
...
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