logo separator

[mkgmap-dev] Re: bad file format error

From Toby Speight T.M.Speight.90 at cantab.net on Sun May 17 20:57:12 BST 2009

0> In article <4A1063F8.8080209 at free.fr>,
0> frmas <URL:mailto:frmas at free.fr> ("Frmas") wrote:

Frmas> <?xml version='1.0' standalone='no'?>

Okay, so the XML is UTF-8 (since no coding is specified).


>> /--------
>> | sed -n -e '148424{' -e 'p' -e 'q' -e '}' cartes/paris.osm | od -t x1c
>> \--------
>> 
>> to view the problematic part.


Frmas> 0000120  6a  6f  73  e9  2c  6a  6f  73  c3  a9  6d  2c  45  73  70
Frmas>           j   o   s 351   ,   j   o   s 303 251   m   ,   E   s   p

That's the problem: E9 2C isn't a valid UTF-8 sequence - it looks like
that part has been encoded as Latin-1.  The later sequence C3 A9 is
okay: a valid UTF-8 2-byte sequence.

So mkgmap is right to reject the file; now the question is, how did that
malformed sequence get in there in the first place?  Could your script
have written it, or has it come from (say) the planet.osm file (or a
subset cut from it)?



More information about the mkgmap-dev mailing list