Skip to content
Permalink
Browse files

revert unnecessary api change

  • Loading branch information
jef-n committed Jun 28, 2013
1 parent fc0b28c commit 93c5599a6613b8c1e89016594918bead916ba9a7
Showing with 4 additions and 8 deletions.
  1. +4 −5 src/core/qgsvectorfilewriter.cpp
  2. +0 −3 src/core/qgsvectorfilewriter.h
@@ -803,11 +803,10 @@ QgsVectorFileWriter::writeAsVectorFormat( QgsVectorLayer* layer,

// enabling transaction on databases that support it
bool transactionsEnabled = true;
OGRLayerH ogrCurrentLayer = writer->getLayer();

if ( OGRERR_NONE != OGR_L_StartTransaction(ogrCurrentLayer) )
if ( OGRERR_NONE != OGR_L_StartTransaction( writer->mLayer ) )
{
QgsDebugMsg("Error when trying to enable transactions on OGRLayer.");
QgsDebugMsg( "Error when trying to enable transactions on OGRLayer." );
transactionsEnabled = false;
}

@@ -874,9 +873,9 @@ QgsVectorFileWriter::writeAsVectorFormat( QgsVectorLayer* layer,

if ( transactionsEnabled )
{
if ( OGRERR_NONE != OGR_L_CommitTransaction(ogrCurrentLayer) )
if ( OGRERR_NONE != OGR_L_CommitTransaction( writer->mLayer ) )
{
QgsDebugMsg("Error while commiting transaction on OGRLayer.");
QgsDebugMsg( "Error while commiting transaction on OGRLayer." );
}
}

@@ -154,9 +154,6 @@ class CORE_EXPORT QgsVectorFileWriter

double symbologyScaleDenominator() const { return mSymbologyScaleDenominator; }
void setSymbologyScaleDenominator( double d ) { mSymbologyScaleDenominator = d; }

/**Returns OGRLayer used to begin and commit transactions on database*/
OGRLayerH getLayer() { return mLayer; }

protected:
//! @note not available in python bindings

0 comments on commit 93c5599

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