Skip to content
Permalink
Browse files
Fix build
  • Loading branch information
nyalldawson committed Dec 20, 2021
1 parent 78f6e2e commit 43568f2670e31085440e208c638fcd80a8055548
Showing with 3 additions and 3 deletions.
  1. +3 −3 src/process/qgsprocess.cpp
@@ -347,14 +347,14 @@ int QgsProcessingExec::run( const QStringList &constArgs )
if ( args.size() == 4 && args.at( 3 ) == '-' )
{
// read arguments as JSON value from stdin
std::string stdin;
std::string stdinJson;
for ( std::string line; std::getline( std::cin, line ); )
{
stdin.append( line + '\n' );
stdinJson.append( line + '\n' );
}

QString error;
const QVariantMap json = QgsJsonUtils::parseJson( stdin, error ).toMap();
const QVariantMap json = QgsJsonUtils::parseJson( stdinJson, error ).toMap();
if ( !error.isEmpty() )
{
std::cerr << QStringLiteral( "Could not parse JSON parameters: %1" ).arg( error ).toLocal8Bit().constData() << std::endl;

0 comments on commit 43568f2

Please sign in to comment.