Clean up trailing whitespaces
This commit is contained in:
+15
-15
@@ -83,7 +83,7 @@ bool Pty::flowControlEnabled() const
|
||||
pty()->tcGetAttr(&ttmode);
|
||||
return ttmode.c_iflag & IXOFF &&
|
||||
ttmode.c_iflag & IXON;
|
||||
}
|
||||
}
|
||||
qWarning() << "Unable to get flow control status, terminal not connected.";
|
||||
return false;
|
||||
}
|
||||
@@ -110,7 +110,7 @@ void Pty::setUtf8Mode(bool enable)
|
||||
void Pty::setErase(char erase)
|
||||
{
|
||||
_eraseChar = erase;
|
||||
|
||||
|
||||
if (pty()->masterFd() >= 0)
|
||||
{
|
||||
struct ::termios ttmode;
|
||||
@@ -142,7 +142,7 @@ void Pty::addEnvironmentVariables(const QStringList& environment)
|
||||
|
||||
// split on the first '=' character
|
||||
int pos = pair.indexOf('=');
|
||||
|
||||
|
||||
if ( pos >= 0 )
|
||||
{
|
||||
QString variable = pair.left(pos);
|
||||
@@ -153,10 +153,10 @@ void Pty::addEnvironmentVariables(const QStringList& environment)
|
||||
}
|
||||
}
|
||||
|
||||
int Pty::start(const QString& program,
|
||||
const QStringList& programArguments,
|
||||
const QStringList& environment,
|
||||
ulong winid,
|
||||
int Pty::start(const QString& program,
|
||||
const QStringList& programArguments,
|
||||
const QStringList& environment,
|
||||
ulong winid,
|
||||
bool addToUtmp
|
||||
//const QString& dbusService,
|
||||
//const QString& dbusSession
|
||||
@@ -164,7 +164,7 @@ int Pty::start(const QString& program,
|
||||
{
|
||||
clearProgram();
|
||||
|
||||
// For historical reasons, the first argument in programArguments is the
|
||||
// For historical reasons, the first argument in programArguments is the
|
||||
// name of the program to execute, so create a list consisting of all
|
||||
// but the first argument to pass to setProgram()
|
||||
Q_ASSERT(programArguments.count() >= 1);
|
||||
@@ -204,10 +204,10 @@ int Pty::start(const QString& program,
|
||||
|
||||
if (_eraseChar != 0)
|
||||
ttmode.c_cc[VERASE] = _eraseChar;
|
||||
|
||||
|
||||
if (!pty()->tcSetAttr(&ttmode))
|
||||
qWarning() << "Unable to set terminal attributes.";
|
||||
|
||||
|
||||
pty()->setWinSize(_windowLines, _windowColumns);
|
||||
|
||||
KProcess::start();
|
||||
@@ -281,14 +281,14 @@ void Pty::sendData(const char* data, int length)
|
||||
if (!length)
|
||||
return;
|
||||
|
||||
if (!pty()->write(data,length))
|
||||
if (!pty()->write(data,length))
|
||||
{
|
||||
qWarning() << "Pty::doSendJobs - Could not send input data to terminal process.";
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
void Pty::dataReceived()
|
||||
void Pty::dataReceived()
|
||||
{
|
||||
QByteArray data = pty()->readAll();
|
||||
emit receivedData(data.constData(),data.count());
|
||||
@@ -312,7 +312,7 @@ int Pty::foregroundProcessGroup() const
|
||||
if ( pid != -1 )
|
||||
{
|
||||
return pid;
|
||||
}
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
@@ -320,9 +320,9 @@ int Pty::foregroundProcessGroup() const
|
||||
void Pty::setupChildProcess()
|
||||
{
|
||||
KPtyProcess::setupChildProcess();
|
||||
|
||||
|
||||
// reset all signal handlers
|
||||
// this ensures that terminal applications respond to
|
||||
// this ensures that terminal applications respond to
|
||||
// signals generated via key sequences such as Ctrl+C
|
||||
// (which sends SIGINT)
|
||||
struct sigaction action;
|
||||
|
||||
Reference in New Issue
Block a user