Skip to content

Commit

Permalink
set SHAPE_ENCODING to "" when creating new shapefile (follows up 4fb9879
Browse files Browse the repository at this point in the history
)
  • Loading branch information
minorua committed Apr 26, 2013
1 parent 5616cfa commit f7cce9c
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/providers/ogr/qgsogrprovider.cpp
Expand Up @@ -1851,6 +1851,9 @@ QGISEXTERN bool createEmptyDataSource( const QString &uri,
if ( driverName == "ESRI Shapefile" )
{
papszOptions = CSLSetNameValue( papszOptions, "ENCODING", encoding.toLocal8Bit().data() );
// OGR Shapefile fails to create fields if given encoding is not supported by its side
// so disable encoding conversion of OGR Shapefile layer
CPLSetConfigOption( "SHAPE_ENCODING", "" );
}

OGRLayerH layer;
Expand Down

0 comments on commit f7cce9c

Please sign in to comment.