[Libreoffice-commits] online.git: Branch 'private/Ashod/nonblocking' - net/Socket.hpp

Ashod Nakashian ashod.nakashian at collabora.co.uk
Thu Mar 2 05:14:33 UTC 2017


 net/Socket.hpp |   18 +++++++-----------
 1 file changed, 7 insertions(+), 11 deletions(-)

New commits:
commit 7dd1686f0d22f6b08a9b0dd5709dd628afc8df4a
Author: Ashod Nakashian <ashod.nakashian at collabora.co.uk>
Date:   Wed Mar 1 21:24:17 2017 -0500

    nb: disable hex dumping
    
    No longer necessary to have them enabled
    permanently, especially that they affect
    performance significantly negatively.
    
    Change-Id: I02ef99da00ba4ecb8e24647ee372a03d79d07fe7

diff --git a/net/Socket.hpp b/net/Socket.hpp
index fe4a721..55f264a 100644
--- a/net/Socket.hpp
+++ b/net/Socket.hpp
@@ -471,7 +471,7 @@ protected:
         if (log.trace()) {
             LOG_TRC("#" << getFD() << ": Incoming data buffer " << _inBuffer.size() <<
                     " bytes, closeSocket? " << closed);
-            log.dump("", &_inBuffer[0], _inBuffer.size());
+            // log.dump("", &_inBuffer[0], _inBuffer.size());
         }
 
         // If we have data, allow the app to consume.
@@ -518,17 +518,13 @@ protected:
                 len = writeData(&_outBuffer[0], _outBuffer.size());
 
                 auto& log = Log::logger();
-                if (log.trace()) {
-                    if (len > 0)
-                    {
-                        LOG_TRC("#" << getFD() << ": Wrote outgoing data " << len << " bytes");
-                        log.dump("", &_outBuffer[0], len);
-                    }
-                    else
-                    {
-                        LOG_SYS("#" << getFD() << ": Wrote outgoing data " << len << " bytes");
-                    }
+                if (log.trace() && len > 0) {
+                    LOG_TRC("#" << getFD() << ": Wrote outgoing data " << len << " bytes");
+                    // log.dump("", &_outBuffer[0], len);
                 }
+
+                if (len <= 0)
+                    LOG_SYS("#" << getFD() << ": Wrote outgoing data " << len << " bytes");
             }
             while (len < 0 && errno == EINTR);
 


More information about the Libreoffice-commits mailing list