labexp / osmtracker-android

GPS tracking tool for OpenStreetMap
GNU General Public License v3.0
495 stars 231 forks source link

Upload failure (XML parser error) when either `title` or `description` contains ampersand character(s) #313

Open Lee-Carre opened 3 years ago

Lee-Carre commented 3 years ago

OSMtracker v1.0.1 on Android v10 on SM-A405FN

When uploading a GNSS trace whose metadata (title or description) contains any ampersand characters, the upload fails (osm.org reports, via e-mail, that there was an XML parser error) even though OSMtracker itself doesn't notify about this failure and the UI indicates success.

Are ampersands being (correctly) escaped in the XML? That seems to be the most likely cause.

Lee-Carre commented 3 years ago

When uploading a GNSS trace whose metadata (title or description) contains any ampersand characters, the upload fails (osm.org reports, via e-mail, that there was an XML parser error)

For clarity; after editing the trace to replace or otherwise remove ampersands, the same set of track-points uploads (and is parsed) successfully.

musoke commented 2 years ago

I can confirm this bug. Submitting a trace where the description contains an ampersand results in an OSM error via email.