logo separator

[mkgmap-dev] missing check for option --family-id

From Gerd Petermann GPetermann_muenchen at hotmail.com on Tue Apr 7 11:08:04 BST 2020

Hi all,
in the garmin forum there is a discussion about the range :
https://forum.openstreetmap.org/viewtopic.php?pid=782395#p782395

The current options.txt says 
--family-id=integer
    This is an integer that identifies a family of products. Range: [1..9999]
    Default: 6324 

This limit is neither checked nor is it correct. The corresponding value is stored in a two byte field and most mkgmap sources interpret it as a 16-bit-unsigned integer.
However, in class uk.me.parabola.tdbfmt.HeaderBlock the field is stored in a short (signed 16-bit-int). 

My conclusion: We should print a warning when the value given in --family-id is < 0 or > 32767.

Gerd


More information about the mkgmap-dev mailing list