Skip to content
Snippets Groups Projects
Commit fae7a9fa authored by ck's avatar ck
Browse files

Maemo: Add missing initialization.

Task-number: QTCREATORBUG-1461 (part 1)

Conflicts:

	src/plugins/qt4projectmanager/qt-maemo/maemosshthread.cpp
	src/plugins/qt4projectmanager/qt-maemo/maemosshthread.h
parent 058d76fc
No related branches found
No related tags found
No related merge requests found
...@@ -104,8 +104,7 @@ bool MaemoSshRunner::runInternal() ...@@ -104,8 +104,7 @@ bool MaemoSshRunner::runInternal()
createConnection(); createConnection();
connect(m_connection.data(), SIGNAL(remoteOutput(QByteArray)), connect(m_connection.data(), SIGNAL(remoteOutput(QByteArray)),
this, SLOT(handleRemoteOutput(QByteArray))); this, SLOT(handleRemoteOutput(QByteArray)));
m_endMarkerCount = 0; initState();
m_promptEncountered = false;
if (!m_connection->start()) if (!m_connection->start())
return false; return false;
if (stopRequested()) if (stopRequested())
...@@ -115,6 +114,13 @@ bool MaemoSshRunner::runInternal() ...@@ -115,6 +114,13 @@ bool MaemoSshRunner::runInternal()
return !m_connection->hasError(); return !m_connection->hasError();
} }
void MaemoSshRunner::initState()
{
m_endMarkerCount = 0;
m_promptEncountered = false;
m_potentialEndMarkerPrefix.clear();
}
void MaemoSshRunner::handleRemoteOutput(const QByteArray &curOutput) void MaemoSshRunner::handleRemoteOutput(const QByteArray &curOutput)
{ {
const QByteArray output = m_potentialEndMarkerPrefix + curOutput; const QByteArray output = m_potentialEndMarkerPrefix + curOutput;
......
...@@ -97,6 +97,7 @@ signals: ...@@ -97,6 +97,7 @@ signals:
private: private:
virtual bool runInternal(); virtual bool runInternal();
Q_SLOT void handleRemoteOutput(const QByteArray &output); Q_SLOT void handleRemoteOutput(const QByteArray &output);
void initState();
static const QByteArray EndMarker; static const QByteArray EndMarker;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment