Ignore:
Timestamp:
07/15/13 14:57:33 (15 months ago)
Author:
Kris Moore <kris@…>
Branches:
master, 9.2-release, releng/10.0, releng/10.0.1, releng/10.0.2, releng/10.0.3
Children:
2046091
Parents:
aac79d5c
Message:

Update qsudo, since we like to see stdout / stderr messages ;)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src-qt4/qsudo/mainwindow.cpp

    r33b8b3a r1f14f705  
    4848     tP->waitForFinished(500); 
    4949     QCoreApplication::processEvents(); 
    50      qDebug() << "Waiting..."; 
    5150  } 
    5251  if ( tP->exitCode() != 0 ) 
     
    7675  sudoProc->write(passwordLineEdit->text().toLatin1() + "\n"); 
    7776  connect( sudoProc, SIGNAL(finished(int, QProcess::ExitStatus)), this, SLOT(slotProcDone() ) ); 
     77  connect( sudoProc, SIGNAL(readyReadStandardError()), this, SLOT(slotPrintStdErr() ) ); 
     78  connect( sudoProc, SIGNAL(readyReadStandardOutput()), this, SLOT(slotPrintStdOut() ) ); 
    7879  while(sudoProc->state() == QProcess::Starting ) { 
    7980     sudoProc->waitForFinished(500); 
    8081     QCoreApplication::processEvents(); 
    8182  } 
     83} 
     84 
     85void MainWindow::slotPrintStdErr() 
     86{ 
     87  QTextStream cout(stderr);  
     88  cout << sudoProc->readAllStandardError(); 
     89} 
     90 
     91void MainWindow::slotPrintStdOut() 
     92{ 
     93  QTextStream cout(stdout);  
     94  cout << sudoProc->readAllStandardOutput(); 
    8295} 
    8396 
Note: See TracChangeset for help on using the changeset viewer.