PostGIS Connector Bug 1536 Fix

Andreas Albarello andreas.albarello at TERRITORIUMONLINE.COM
Fri Aug 18 06:41:46 EDT 2006


Tamas Szekeres wrote:
> I'm not so far with how the fix was made actually, but i'm a bit
> uncertain whether
> http://mapserver.gis.umn.edu/bugs/show_bug.cgi?id=1549
> was also handled.
> 
> How should we quote the names in the map file properly?


Tamas and all the folks out there,

I've recently come up with a fix for 
http://mapserver.gis.umn.edu/bugs/show_bug.cgi?id=1549 by changing the 
regular expressions used inside the mapfile lexer for parsing strings 
and regular expressions.

This way I'm now able to escape quotes inside strings and slashes inside 
regular expressions by doubling them. I've taken this approach as 
escaping with backslashes would break a vast majority of Windows 
mapfiles out there using the backslash as path delimiter and potentially 
having therefore backslashes as last character of some strings (e.g. 
SHAPEPATH "C:\data\")

I've however not addressed some related issues like accordingly doubling 
quotes in attribute strings coming from shapefiles or other data source 
(for proper comparison inside mapfile expressions) or checking whether 
the mapfile writer would need some adjustments once this fix is applied.

If however, despite the fact that this fix is not actually complete, 
someone is interested in having a look at it, I'm ready to submit it to 
bugzilla.

Best regards,
-- 
--------------------------------------------------------------------
Andreas Albarello
Analysis & SW Development

Territorium Online srl/GmbH
Via Buozzi Str. 12
I 39100 Bolzano/Bozen

Phone:  +39 0471 068611
Fax:    +39 0471 068619

email: andreas.albarello at territoriumonline.com
web:   http://www.territoriumonline.com
--------------------------------------------------------------------



More information about the mapserver-dev mailing list