<html>
<head>
<style><!--
.hmmessage P
{
margin:0px;
padding:0px
}
body.hmmessage
{
font-size: 12pt;
font-family:Calibri
}
--></style></head>
<body class='hmmessage'><div dir='ltr'>Hi Uli,<br><br>yes, you are probably right. <br>BTW: This seems to be related to a new HashMap implementation in Java 8. <br>In my environtment (with Java 7), the compareTo() method is never called<br>which could explain why nobody else has reported the problem.<br><br>Gerd<br><br><div>> Date: Thu, 6 Nov 2014 00:58:06 -0800<br>> From: ulibaer@gmail.com<br>> To: mkgmap-dev@lists.mkgmap.org.uk<br>> Subject: Re: [mkgmap-dev] NPE with mkgmap 3344!<br>> <br>> BTW:<br>> Since there is a check against City object being null before the compare<br>> method:<br>> <br>> <br>> // TODO: look at what this is doing...<br>> if(city != null && other.city != null)<br>> return city.getName().compareTo(other.city.getName()); <--- Here<br>> happens the NPE<br>> if (hashCode() == other.hashCode())<br>> return 0;<br>> <br>> <br>> I suspect the getName()-function from City object to return <null> in some<br>> cases.<br>> I'm @ work right now and can't explore, but i remember City.getName()<br>> checking for Label != <null> but then calling Label.getText(), which does<br>> *not* check for <null>.<br>> <br>> Best regards, Uli<br>> <br>> <br>> <br>> --<br>> View this message in context: http://gis.19327.n5.nabble.com/NPE-with-mkgmap-3320-tp5813472p5823349.html<br>> Sent from the Mkgmap Development mailing list archive at Nabble.com.<br>> _______________________________________________<br>> mkgmap-dev mailing list<br>> mkgmap-dev@lists.mkgmap.org.uk<br>> http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev<br></div>                                            </div></body>
</html>