base: Remove SOCK_CLOEXEC from socketCloexec.
63c53e21fe ("base: Add SOCK_CLOEXEC when creating/accepting sockets")
accidentally left SOCK_CLOEXEC as socketCloexec parameter, remove
it as socketCloexec will add that parameter, and it'll not compile
on platforms that do not provide the flag.
Change-Id: I30e6fa1824b0258a325b53422585a9a362de4dff
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/49947
Reviewed-by: Yu-hsin Wang <yuhsingw@google.com>
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Maintainer: Jason Lowe-Power <power.jg@gmail.com>
Tested-by: kokoro <noreply+kokoro@google.com>
This commit is contained in:
@@ -126,7 +126,7 @@ ListenSocket::listen(int port, bool reuse)
|
||||
|
||||
// only create socket if not already created by a previous call
|
||||
if (fd == -1) {
|
||||
fd = socketCloexec(PF_INET, SOCK_STREAM | SOCK_CLOEXEC, 0);
|
||||
fd = socketCloexec(PF_INET, SOCK_STREAM, 0);
|
||||
if (fd < 0)
|
||||
panic("Can't create socket:%s !", strerror(errno));
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user