Merge pull request #1370 from varjolintu/browser_cpu_fix

High CPU fix for Linux
This commit is contained in:
Janek Bevendorff 2018-01-11 09:32:50 +01:00 committed by GitHub
commit 6aaa89a23c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -93,9 +93,10 @@ void NativeMessagingHost::readLength()
{
quint32 length = 0;
std::cin.read(reinterpret_cast<char*>(&length), 4);
if (!std::cin.eof() && length > 0)
{
if (!std::cin.eof() && length > 0) {
readStdIn(length);
} else {
m_notifier->setEnabled(false);
}
}