Skip to content

Commit

Permalink
Revert "eliminate local 8-bit conversion in qcumber, which fixes #28
Browse files Browse the repository at this point in the history
…when

another app instance is running (at least on Windows)" as it causes app to
hang at exit

This reverts commit 2f9fff8.
  • Loading branch information
krzemin committed Dec 12, 2015
1 parent 75cae32 commit b26f0d5
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion src/qcumber/qinterprocesschannel.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ void QInterProcessChannel::sendMessage()
*/
void QInterProcessChannel::sendMessage(const QString& s)
{
sendMessage(s);
sendMessage(s.toLocal8Bit());
}
/*!
\brief Send a message to server instance
Expand Down
2 changes: 1 addition & 1 deletion src/qcumber/qinterprocesschannel_win32.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ void QInterProcessChannel::sendMessage()
*/
void QInterProcessChannel::sendMessage(const QString& s)
{
sendMessage(s);
sendMessage(s.toLocal8Bit());
}
/*!
\brief Send a message to server instance
Expand Down
6 changes: 3 additions & 3 deletions src/qcumber/qmanagedrequest.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ QManagedRequest& QManagedRequest::operator = (const QManagedRequest& r)

QString QManagedRequest::toString() const
{
return joinArguments(sCommand, lArguments);
return QString::fromLocal8Bit(joinArguments(sCommand, lArguments));
}

QManagedRequest QManagedRequest::fromString(const QString& s)
Expand Down Expand Up @@ -105,7 +105,7 @@ QByteArray QManagedRequest::joinArguments(const QString& cmd, const QStringList&
{
QByteArray msg;

msg += cmd;
msg += cmd.toLocal8Bit();

foreach ( QString a, l )
{
Expand All @@ -116,7 +116,7 @@ QByteArray QManagedRequest::joinArguments(const QString& cmd, const QStringList&
a = "\"" + a + "\"";

msg += " ";
msg += a;
msg += a.toLocal8Bit();
}

return msg;
Expand Down
2 changes: 1 addition & 1 deletion src/qcumber/qmanagedsocket.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ void QManagedSocket::readyRead()
{
if ( pSocket )
{
QString msg = pSocket->readAll();
QString msg = QString::fromLocal8Bit(pSocket->readAll());

emit message(msg);
emit message(msg, this);
Expand Down

0 comments on commit b26f0d5

Please sign in to comment.