From 9ccb5242ef79b318e7061c60347b4c3c05be05a6 Mon Sep 17 00:00:00 2001 From: akl Date: Wed, 22 Aug 2007 11:22:22 +0000 Subject: [PATCH] Remove duplicates from a list of 'not found' libraries. --- src/SALOME_InstallWizard.cxx | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/src/SALOME_InstallWizard.cxx b/src/SALOME_InstallWizard.cxx index beec2a9..d74f059 100644 --- a/src/SALOME_InstallWizard.cxx +++ b/src/SALOME_InstallWizard.cxx @@ -1663,16 +1663,17 @@ void SALOME_InstallWizard::updateAvailableSpace() void SALOME_InstallWizard::checkFLibResult() { if ( checkFLibProc->normalExit() && checkFLibProc->exitStatus() == 1 ) { - QString notFoundLibs; + QStringList notFoundLibsList; + QString record = ""; while ( checkFLibProc->canReadLineStdout() ) { - notFoundLibs.append( checkFLibProc->readLineStdout() ); - if ( checkFLibProc->canReadLineStdout() ) - notFoundLibs.append( "\n" ); + record = checkFLibProc->readLineStdout(); + if ( !record.isEmpty() && !notFoundLibsList.contains( record ) ) + notFoundLibsList.append( record ); } QMessageBox::warning( this, tr( "Warning" ), tr( "The following libraries are absent on current system:\n" - "%1").arg( notFoundLibs ), + "%1").arg( notFoundLibsList.join( "\n" ) ), QMessageBox::Ok, QMessageBox::NoButton, QMessageBox::NoButton ); -- 2.39.2