summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2017-07-21 12:10:41 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2017-07-22 08:49:43 +0200
commit760a7791a2d4d389d91dd35deb65dc72ff9d4f6a (patch)
treefa94616dc14437ae6fe2a1f4b837f9c06754ae20
parente5ee29737edc08874ae854c459198aa4fba59dd8 (diff)
loplugin:unusedfields in io
Change-Id: I8be28fa2ed1e005c76eafc60746620338c8a49ac Reviewed-on: https://gerrit.libreoffice.org/40291 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
-rw-r--r--compilerplugins/clang/unusedfields.readonly.results2
-rw-r--r--io/source/acceptor/acc_socket.cxx5
2 files changed, 3 insertions, 4 deletions
diff --git a/compilerplugins/clang/unusedfields.readonly.results b/compilerplugins/clang/unusedfields.readonly.results
index 9e3625eabb2a..1fb3f0f431cd 100644
--- a/compilerplugins/clang/unusedfields.readonly.results
+++ b/compilerplugins/clang/unusedfields.readonly.results
@@ -674,8 +674,6 @@ include/vcl/opengl/OpenGLContext.hxx:57
OpenGLCapabilitySwitch mbLimitedShaderRegisters _Bool
include/xmloff/nmspmap.hxx:70
SvXMLNamespaceMap sEmpty const class rtl::OUString
-io/source/acceptor/acc_socket.cxx:89
- io_acceptor::SocketConnection m_addr ::osl::SocketAddr
jvmfwk/plugins/sunmajor/pluginlib/util.cxx:251
jfw_plugin::FileHandleReader m_aBuffer sal_Char [1024]
libreofficekit/qa/gtktiledviewer/gtv-application-window.hxx:50
diff --git a/io/source/acceptor/acc_socket.cxx b/io/source/acceptor/acc_socket.cxx
index 8a9907bbc67e..6446c5fa14b6 100644
--- a/io/source/acceptor/acc_socket.cxx
+++ b/io/source/acceptor/acc_socket.cxx
@@ -86,7 +86,6 @@ namespace io_acceptor {
void completeConnectionString();
::osl::StreamSocket m_socket;
- ::osl::SocketAddr m_addr;
oslInterlockedCount m_nStatus;
OUString m_sDescription;
@@ -350,7 +349,9 @@ namespace io_acceptor {
}
pConn->completeConnectionString();
- OUString remoteHostname = pConn->m_addr.getHostname();
+ ::osl::SocketAddr remoteAddr;
+ pConn->m_socket.getPeerAddr(remoteAddr);
+ OUString remoteHostname = remoteAddr.getHostname();
// we enable tcpNoDelay for loopback connections because
// it can make a significant speed difference on linux boxes.
if( m_bTcpNoDelay || remoteHostname == "localhost" ||