added bad-TRs analysis to pre-processor

This commit is contained in:
Arndt Brenschede 2022-01-15 10:05:06 +01:00
parent 8fd38da5c9
commit 771770af22
5 changed files with 163 additions and 46 deletions

View file

@ -175,11 +175,11 @@ public class OsmNodeP extends OsmLinkP
RestrictionData r = getFirstRestriction();
while( r != null )
{
if ( r.fromLon != 0 && r.toLon != 0 )
if ( r.isValid() && r.fromLon != 0 && r.toLon != 0 )
{
mc.writeBoolean( true ); // restriction follows
mc.writeShort( r.exceptions );
mc.writeBoolean( r.isPositive );
mc.writeBoolean( r.isPositive() );
mc.writeInt( r.fromLon );
mc.writeInt( r.fromLat );
mc.writeInt( r.toLon );