Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Fix clazy warning
  • Loading branch information
nyalldawson committed May 15, 2023
1 parent 5efa6c0 commit 7cf4afd
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions src/gui/ogr/qgsvectorlayersaveasdialog.cpp
Expand Up @@ -437,9 +437,8 @@ void QgsVectorLayerSaveAsDialog::mFormatComboBox_currentIndexChanged( int idx )
// to avoid double extensions like .gpkg.shp
if ( !mFilename->filePath().isEmpty() )
{
QRegularExpression rx( "\\.(.*?)[\\s]" );
QString ext;
ext = rx.match( QgsVectorFileWriter::filterForDriver( format() ) ).captured( 1 );
const thread_local QRegularExpression rx( "\\.(.*?)[\\s]" );
const QString ext = rx.match( QgsVectorFileWriter::filterForDriver( format() ) ).captured( 1 );
if ( !ext.isEmpty() )
{
QFileInfo fi( mFilename->filePath() );
Expand Down

0 comments on commit 7cf4afd

Please sign in to comment.