Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
[BACKPORT] add extension to new GPX file if user ommit it (fix #4623)
  • Loading branch information
alexbruy committed Dec 16, 2011
1 parent 42b6d02 commit c336eca
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/plugins/gps_importer/qgsgpsplugin.cpp
Expand Up @@ -164,6 +164,10 @@ void QgsGPSPlugin::createGPX()
tr( "GPS eXchange file (*.gpx)" ) );
if ( !fileName.isEmpty() )
{
if ( !fileName.toLower().endsWith( ".gpx" ) )
{
fileName += ".gpx";
}
QFileInfo fileInfo( fileName );
std::ofstream ofs( fileName.toUtf8() );
if ( !ofs )
Expand Down

0 comments on commit c336eca

Please sign in to comment.