Skip to content
Permalink
Browse files

Fix some QProcess deprecation warnings

  • Loading branch information
nyalldawson committed Oct 2, 2020
1 parent fa28c42 commit 7a38388a8762503b0bdba55065fffea2ff24137a
Showing with 5 additions and 5 deletions.
  1. +1 −1 src/core/qgsapplication.cpp
  2. +4 −4 src/plugins/gps_importer/qgsgpsplugin.cpp
@@ -1109,7 +1109,7 @@ QString QgsApplication::userLoginName()
#elif QT_CONFIG(process)
QProcess process;

process.start( QStringLiteral( "whoami" ) );
process.start( QStringLiteral( "whoami" ), QStringList() );
process.waitForFinished();
*sUserName() = process.readAllStandardOutput().trimmed();
#endif
@@ -255,7 +255,7 @@ void QgsGpsPlugin::importGPSFile( const QString &inputFileName, QgsBabelFormat *
QgsDebugMsg( QStringLiteral( "Import command: " ) + babelArgs.join( "|" ) );

QProcess babelProcess;
babelProcess.start( babelArgs.join( QStringLiteral( " " ) ) );
babelProcess.start( babelArgs.value( 0 ), babelArgs.mid( 1 ) );
if ( !babelProcess.waitForStarted() )
{
QMessageBox::warning( nullptr, tr( "Import GPS File" ),
@@ -334,7 +334,7 @@ void QgsGpsPlugin::convertGPSFile( const QString &inputFileName,
QgsDebugMsg( QStringLiteral( "Conversion command: " ) + babelArgs.join( "|" ) );

QProcess babelProcess;
babelProcess.start( babelArgs.join( QStringLiteral( " " ) ) );
babelProcess.start( babelArgs.value( 0 ), babelArgs.mid( 1 ) );
if ( !babelProcess.waitForStarted() )
{
QMessageBox::warning( nullptr, tr( "Convert GPS File" ),
@@ -425,7 +425,7 @@ void QgsGpsPlugin::downloadFromGPS( const QString &device, const QString &port,
QgsDebugMsg( QStringLiteral( "Download command: " ) + babelArgs.join( "|" ) );

QProcess babelProcess;
babelProcess.start( babelArgs.join( QStringLiteral( " " ) ) );
babelProcess.start( babelArgs.value( 0 ), babelArgs.mid( 1 ) );
if ( !babelProcess.waitForStarted() )
{
QMessageBox::warning( nullptr, tr( "Download from GPS" ),
@@ -515,7 +515,7 @@ void QgsGpsPlugin::uploadToGPS( QgsVectorLayer *gpxLayer, const QString &device,
QgsDebugMsg( QStringLiteral( "Upload command: " ) + babelArgs.join( "|" ) );

QProcess babelProcess;
babelProcess.start( babelArgs.join( QStringLiteral( " " ) ) );
babelProcess.start( babelArgs.value( 0 ), babelArgs.mid( 1 ) );
if ( !babelProcess.waitForStarted() )
{
QMessageBox::warning( nullptr, tr( "Upload to GPS" ),

0 comments on commit 7a38388

Please sign in to comment.
You can’t perform that action at this time.