MapGuide crash on a layer with a malformed tooltip
|Reported by:||gabrimonfa||Owned by:|
mapguide 2.5.2 32 bit @ centos 6 OGR Provider (with libgdal recompiled to support PostgreSQL).
one of my colleague by mistake set a layer tooltip mixing double quotes and single quotes. In particular, since the tooltip had some words within single quotes, he surrounded the entire tooltip within double quotes, instead of properly escaping single quotes. The wrong tooltip was like
<Tooltip>"Something like this 'bla bla' R. G. 'bla bla'"</Tooltip>
When hovering the mouse on the polygon with this tooltip MapGuide 2.5.2 (but also 2.4.0) crashed without logging anything. This happened always, so it's easily reproducible.
Validating the problematic layer with Maestro did not reveal the problem. Fixing the tooltip solved the problem.
I'm worried about this crash because we have a lot of maps and many different people working on map authoring, so wrong tooltip may happens from time to time and I've not yet found a systematic way to check them.
Step needed to reproduce the bug:
- unzip the test.zip into an aliased folder called "mapguide_data"
- load mgp into mapguide
- connect to the server with Maestro
- Open maestro options under Tool>Options. In the tab Editors uncheck "Preview with local map viewer (where applicable)". We need this in order to preview the map in a browser, previewing in local map viewer does not reveal the bug.
- open the layer in maestro and preview the layer using Preview button
- In the browser window, pan to one of the geometry
- Hover the mouse inside the geometry.
- No tooltip is showed, mapguide crashed