wsd: logging corrections

Change-Id: I35c52494137ea174c218bf936bc2440634036e3e
Reviewed-on: https://gerrit.libreoffice.org/37889
Reviewed-by: Ashod Nakashian <ashnakash@gmail.com>
Tested-by: Ashod Nakashian <ashnakash@gmail.com>
This commit is contained in:
Ashod Nakashian 2017-05-20 13:28:09 -04:00 committed by Ashod Nakashian
parent f47936a2da
commit 873cbcbe91
4 changed files with 7 additions and 7 deletions

View file

@ -75,7 +75,7 @@ void ChildSession::disconnect()
bool ChildSession::_handleInput(const char *buffer, int length)
{
LOG_TRC(getName() + ": handling [" << getAbbreviatedMessage(buffer, length) << "].");
LOG_TRC(getName() << ": handling [" << getAbbreviatedMessage(buffer, length) << "].");
const std::string firstLine = getFirstLine(buffer, length);
const auto tokens = LOOLProtocol::tokenize(firstLine.data(), firstLine.size());
@ -348,7 +348,7 @@ bool ChildSession::loadDocument(const char * /*buffer*/, int /*length*/, const s
return false;
}
LOG_INF("Created new view with viewid: [" << _viewId << + "] for username: [" <<
LOG_INF("Created new view with viewid: [" << _viewId << "] for username: [" <<
_userName << "] in session: [" << getId() << "].");
std::unique_lock<std::mutex> lockLokDoc(_docManager.getDocumentMutex());

View file

@ -497,7 +497,7 @@ bool ClientSession::handleKitToClientMessage(const char* buffer, const int lengt
{
const auto payload = std::make_shared<Message>(buffer, length, Message::Dir::Out);
LOG_TRC(getName() + ": handling kit-to-client [" << payload->abbr() << "].");
LOG_TRC(getName() << ": handling kit-to-client [" << payload->abbr() << "].");
const std::string& firstLine = payload->firstLine();
const auto docBroker = _docBroker.lock();

View file

@ -460,7 +460,7 @@ bool DocumentBroker::load(const std::shared_ptr<ClientSession>& session, const s
// Mark the session as 'Document owner' if WOPI hosts supports it
if (userid == _storage->getFileInfo()._ownerId)
{
LOG_DBG("Session [" + sessionId + "] is the document owner");
LOG_DBG("Session [" << sessionId << "] is the document owner");
session->setDocumentOwner(true);
}

View file

@ -291,7 +291,7 @@ void FileServerRequestHandler::readDirToHash(const std::string &basePath, const
struct stat fileStat;
DIR *workingdir;
LOG_TRC("Pre-reading directory: " << basePath + path << "\n");
LOG_TRC("Pre-reading directory: " << basePath << path << "\n");
workingdir = opendir((basePath + path).c_str());
while ((currentFile = readdir(workingdir)) != NULL)
@ -299,7 +299,7 @@ void FileServerRequestHandler::readDirToHash(const std::string &basePath, const
if (currentFile->d_name[0] == '.')
continue;
std::string relPath = path + "/" + currentFile->d_name;
const std::string relPath = path + '/' + currentFile->d_name;
stat ((basePath + relPath).c_str(), &fileStat);
if (S_ISDIR(fileStat.st_mode))
@ -307,7 +307,7 @@ void FileServerRequestHandler::readDirToHash(const std::string &basePath, const
else if (S_ISREG(fileStat.st_mode))
{
LOG_TRC("Reading file: '" << (basePath + relPath) << " as '" << relPath << "'\n");
LOG_TRC("Reading file: '" << basePath << relPath << " as '" << relPath << "'\n");
std::ifstream file(basePath + relPath, std::ios::binary);