net/ServerSocket: pass UniqueSocketDescriptor&& to OnAccept()

This commit is contained in:
Max Kellermann
2017-08-10 19:13:18 +02:00
parent 492b20a89d
commit 9a5bcc6db0
9 changed files with 35 additions and 28 deletions

View File

@@ -25,6 +25,7 @@
#include "Page.hxx"
#include "IcyMetaDataServer.hxx"
#include "net/SocketError.hxx"
#include "net/UniqueSocketDescriptor.hxx"
#include "Log.hxx"
#include <assert.h>
@@ -185,10 +186,10 @@ HttpdClient::SendResponse()
return true;
}
HttpdClient::HttpdClient(HttpdOutput &_httpd, SocketDescriptor _fd,
HttpdClient::HttpdClient(HttpdOutput &_httpd, UniqueSocketDescriptor &&_fd,
EventLoop &_loop,
bool _metadata_supported)
:BufferedSocket(_fd, _loop),
:BufferedSocket(_fd.Release(), _loop),
httpd(_httpd),
state(REQUEST),
queue_size(0),