diff options
| author | Peter Penz <[email protected]> | 2009-11-10 18:36:13 +0000 |
|---|---|---|
| committer | Peter Penz <[email protected]> | 2009-11-10 18:36:13 +0000 |
| commit | a47dc8edae84ae571ff364351d493cec0be9d3f3 (patch) | |
| tree | ee2c6abed0fcdc67acc4ac5deef4b59c6fd8dc7b /src/versioncontrol/fileviewsvnplugin.cpp | |
| parent | 7b42d2d6cbff82dc8adefc8e05f42a015f59cb03 (diff) | |
never report a success if there was none: check the exit code + status
svn path=/trunk/KDE/kdebase/apps/; revision=1047233
Diffstat (limited to 'src/versioncontrol/fileviewsvnplugin.cpp')
| -rw-r--r-- | src/versioncontrol/fileviewsvnplugin.cpp | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/src/versioncontrol/fileviewsvnplugin.cpp b/src/versioncontrol/fileviewsvnplugin.cpp index 7e56c724c..91a37a878 100644 --- a/src/versioncontrol/fileviewsvnplugin.cpp +++ b/src/versioncontrol/fileviewsvnplugin.cpp @@ -309,9 +309,11 @@ void FileViewSvnPlugin::removeFiles() i18nc("@info:status", "Removed files from SVN repository.")); } -void FileViewSvnPlugin::slotOperationCompleted() +void FileViewSvnPlugin::slotOperationCompleted(int exitCode, QProcess::ExitStatus exitStatus) { - if (m_contextItems.isEmpty()) { + if ((exitStatus != QProcess::NormalExit) || (exitCode != 0)) { + emit errorMessage(m_errorMsg); + } else if (m_contextItems.isEmpty()) { emit operationCompletedMessage(m_operationCompletedMsg); emit versionStatesChanged(); } else { @@ -344,8 +346,8 @@ void FileViewSvnPlugin::execSvnCommand(const QString& svnCommand, void FileViewSvnPlugin::startSvnCommandProcess() { QProcess* process = new QProcess(this); - connect(process, SIGNAL(finished(int)), - this, SLOT(slotOperationCompleted())); + connect(process, SIGNAL(finished(int, QProcess::ExitStatus)), + this, SLOT(slotOperationCompleted(int, QProcess::ExitStatus))); connect(process, SIGNAL(error(QProcess::ProcessError)), this, SLOT(slotOperationError())); |
