[mkgmap-dev] NPE with mkgmap 3344!From Gerd Petermann gpetermann_muenchen at hotmail.com on Thu Nov 6 09:07:17 GMT 2014
Hi Uli, yes, you are probably right. BTW: This seems to be related to a new HashMap implementation in Java 8. In my environtment (with Java 7), the compareTo() method is never called which could explain why nobody else has reported the problem. Gerd > Date: Thu, 6 Nov 2014 00:58:06 -0800 > From: ulibaer at gmail.com > To: mkgmap-dev at lists.mkgmap.org.uk > Subject: Re: [mkgmap-dev] NPE with mkgmap 3344! > > BTW: > Since there is a check against City object being null before the compare > method: > > > // TODO: look at what this is doing... > if(city != null && other.city != null) > return city.getName().compareTo(other.city.getName()); <--- Here > happens the NPE > if (hashCode() == other.hashCode()) > return 0; > > > I suspect the getName()-function from City object to return <null> in some > cases. > I'm @ work right now and can't explore, but i remember City.getName() > checking for Label != <null> but then calling Label.getText(), which does > *not* check for <null>. > > Best regards, Uli > > > > -- > View this message in context: http://gis.19327.n5.nabble.com/NPE-with-mkgmap-3320-tp5813472p5823349.html > Sent from the Mkgmap Development mailing list archive at Nabble.com. > _______________________________________________ > mkgmap-dev mailing list > mkgmap-dev at lists.mkgmap.org.uk > http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://www.mkgmap.org.uk/pipermail/mkgmap-dev/attachments/20141106/e21425c5/attachment.html>
- Previous message: [mkgmap-dev] NPE with mkgmap 3344!
- Next message: [mkgmap-dev] NPE with mkgmap 3320
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the mkgmap-dev mailing list