Skip to content

Commit

Permalink
[DXF export] Replace newline character in layer name by underscore
Browse files Browse the repository at this point in the history
Fixes #15067
  • Loading branch information
rouault committed Jun 18, 2016
1 parent b0c519e commit 04ec683
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/core/dxf/qgsdxfexport.cpp
Expand Up @@ -4101,6 +4101,11 @@ QString QgsDxfExport::dxfLayerName( const QString& name )
layerName.replace( '=', '_' );
layerName.replace( '\'', '_' );

// also remove newline characters (#15067)
layerName.replace( "\r\n", "_" );
layerName.replace( '\r', '_' );
layerName.replace( '\n', '_' );

return layerName.trimmed();
}

Expand Down

0 comments on commit 04ec683

Please sign in to comment.