Skip to content

Commit

Permalink
[processing] use complex delimiter for interpolation data to avoid
Browse files Browse the repository at this point in the history
overlaps with charactes which can be used in the layers source URI (fix #20490)

(cherry picked from commit 17fd86e)
  • Loading branch information
alexbruy committed Jan 22, 2019
1 parent 3de1550 commit 255d510
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion python/plugins/processing/algs/qgis/IdwInterpolation.py
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,7 @@ def processAlgorithm(self, parameters, context, feedback):

layerData = []
layers = []
for row in interpolationData.split(';'):
for row in interpolationData.split('::|::'):
v = row.split('::~::')
data = QgsInterpolator.LayerData()

Expand Down
2 changes: 1 addition & 1 deletion python/plugins/processing/algs/qgis/TinInterpolation.py
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,7 @@ def processAlgorithm(self, parameters, context, feedback):
layerData = []
layers = []
crs = QgsCoordinateReferenceSystem()
for row in interpolationData.split(';'):
for row in interpolationData.split('::|::'):
v = row.split('::~::')
data = QgsInterpolator.LayerData()

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -203,10 +203,10 @@ def value(self):
else:
inputType = QgsInterpolator.SourceBreakLines

layers += '{}::~::{:d}::~::{:d}::~::{:d};'.format(layer.source(),
interpolationSource,
fieldIndex,
inputType)
layers += '{}::~::{:d}::~::{:d}::~::{:d}::|::'.format(layer.source(),
interpolationSource,
fieldIndex,
inputType)
return layers[:-1]


Expand Down

0 comments on commit 255d510

Please sign in to comment.