mirror of
https://github.com/deskflow/deskflow.git
synced 2026-07-01 21:02:39 +08:00
Revert "Cleared buffer on send instead of write #4721"
This reverts commit 7614a21aac.
This commit is contained in:
parent
6075ed9fcd
commit
04c3faec6a
@ -95,6 +95,13 @@ IpcLogOutputter::show(bool showIfEmpty)
|
||||
bool
|
||||
IpcLogOutputter::write(ELevel, const char* text)
|
||||
{
|
||||
if (!m_ipcServer.hasClients(kIpcClientGui)) {
|
||||
if (!m_buffer.empty()) {
|
||||
m_buffer.clear();
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
// ignore events from the buffer thread (would cause recursion).
|
||||
if (m_bufferThread != nullptr &&
|
||||
Thread::getCurrentThread().getID() == m_bufferThreadId) {
|
||||
@ -185,9 +192,6 @@ void
|
||||
IpcLogOutputter::sendBuffer()
|
||||
{
|
||||
if (m_buffer.empty() || !m_ipcServer.hasClients(kIpcClientGui)) {
|
||||
if (!m_buffer.empty()) {
|
||||
m_buffer.clear();
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user