diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2016-07-15 18:09:29 +0200 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2016-07-15 18:09:55 +0200 |
commit | 24d0a0549d068e9a1c111ec1d574b478642b80ef (patch) | |
tree | 8563f410be0fcd38ce011d4a7e843895e24bc753 /desktop | |
parent | 0710fcd58d29d7ba98f0305caab79f9b7b1519a2 (diff) |
Log PipeIpcThread communication
Change-Id: I9e818351a435d39a9d1d8988214185f5bc504e8c
Diffstat (limited to 'desktop')
-rw-r--r-- | desktop/source/app/officeipcthread.cxx | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/desktop/source/app/officeipcthread.cxx b/desktop/source/app/officeipcthread.cxx index 3990944a0e96..99d4994cfd32 100644 --- a/desktop/source/app/officeipcthread.cxx +++ b/desktop/source/app/officeipcthread.cxx @@ -75,6 +75,7 @@ OString readStringFromPipe(osl::StreamPipe & pipe) { char buf[1024]; sal_Int32 n = pipe.recv(buf, SAL_N_ELEMENTS(buf)); if (n <= 0) { + SAL_INFO("desktop.app", "read empty string"); return ""; } bool end = false; @@ -85,7 +86,9 @@ OString readStringFromPipe(osl::StreamPipe & pipe) { str.append(buf, n); //TODO: how does OStringBuffer.append handle overflow? if (end) { - return str.makeStringAndClear(); + auto s = str.makeStringAndClear(); + SAL_INFO("desktop.app", "read <" << s << ">"); + return s; } } } @@ -893,6 +896,7 @@ RequestHandler::Status PipeIpcThread::enable(rtl::Reference<IpcThread> * thread) } aArguments.append('\0'); // finally, write the string onto the pipe + SAL_INFO("desktop.app", "writing <" << aArguments.getStr() << ">"); sal_Int32 n = aStreamPipe.write( aArguments.getStr(), aArguments.getLength()); if (n != aArguments.getLength()) { @@ -1204,6 +1208,7 @@ void PipeIpcThread::execute() } // notify client we're ready to process its args: + SAL_INFO("desktop.app", "writing <" << SEND_ARGUMENTS << ">"); sal_Int32 n = aStreamPipe.write( SEND_ARGUMENTS, SAL_N_ELEMENTS(SEND_ARGUMENTS)); // incl. terminating NUL @@ -1229,6 +1234,7 @@ void PipeIpcThread::execute() if (waitProcessed) handler_->cProcessed.wait(); // processing finished, inform the requesting end: + SAL_INFO("desktop.app", "writing <" << PROCESSING_DONE << ">"); n = aStreamPipe.write( PROCESSING_DONE, SAL_N_ELEMENTS(PROCESSING_DONE)); // incl. terminating NUL |