diff --git a/src/tools/qmlprofiler/commandlistener.cpp b/src/tools/qmlprofiler/commandlistener.cpp index f6943704cad..eb06a35a7f0 100644 --- a/src/tools/qmlprofiler/commandlistener.cpp +++ b/src/tools/qmlprofiler/commandlistener.cpp @@ -45,6 +45,8 @@ void CommandListener::run() QTextStream in(stdin, QIODevice::ReadOnly); do { line = in.readLine(); - emit command(line); + line = line.trimmed(); + if (!line.isEmpty()) + emit command(line); } while (!m_stopRequested && !line.isNull()); }