From 92b47690231337a50d70591cafe04442e11c994a Mon Sep 17 00:00:00 2001 From: dmv Date: Mon, 19 May 2008 07:39:23 +0000 Subject: [PATCH] NPAL19730 EDF 700 ALL : Dump study filename verification too restrictive --- src/SalomeApp/SalomeApp_Application.cxx | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/SalomeApp/SalomeApp_Application.cxx b/src/SalomeApp/SalomeApp_Application.cxx index 894ca64fd..62e7e8386 100644 --- a/src/SalomeApp/SalomeApp_Application.cxx +++ b/src/SalomeApp/SalomeApp_Application.cxx @@ -700,8 +700,10 @@ class DumpStudyFileValidator : public SUIT_FileValidator bool DumpStudyFileValidator::canSave(const QString& file) { - // if file name is not correct... - if ( file.find( QRegExp("[-!?#*&]") ) != -1 ) { + QFileInfo fi( file ); + QString name = fi.fileName(); + + if ( name.find( QRegExp("[-!?#*&]") ) != -1 ) { SUIT_MessageBox::error1 ( parent(), QObject::tr("WRN_WARNING"), QObject::tr("WRN_FILE_NAME_BAD"), -- 2.39.2