Skip to content

Commit 4d61fb5

Browse files
committed
[oracle] Fix crash when adding a feature with missing attributes
to data provider
1 parent a74414c commit 4d61fb5

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/providers/oracle/qgsoracleprovider.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1298,7 +1298,7 @@ bool QgsOracleProvider::addFeatures( QgsFeatureList &flist, QgsFeatureSink::Flag
12981298

12991299
for ( int i = 0; i < fieldId.size(); i++ )
13001300
{
1301-
QVariant value = attributevec[ fieldId[i] ];
1301+
QVariant value = attributevec.value( fieldId[i], QVariant() );
13021302

13031303
QString v;
13041304
if ( !value.isValid() )

0 commit comments

Comments
 (0)