
Hi, I've got a NPE while testing my style-file ( http://www.aighes.de/data/rrk_style.zip ). Any guesses were the fault could be? Maybe a better errormessage could be generated by mkgmap in this case? Henning java -jar -Xmx6000M bin\mkgmap.jar --style-file=data\style_rrk --list-styles Time started: Fri Sep 28 14:34:32 CEST 2012 The following styles are available: Exception in thread "main" java.lang.NullPointerException at uk.me.parabola.mkgmap.osmstyle.RuleFileReader.isIndexable(RuleFileReader.java:239) at uk.me.parabola.mkgmap.osmstyle.RuleFileReader.isSolved(RuleFileReader.java:247) at uk.me.parabola.mkgmap.osmstyle.RuleFileReader.isFinished(RuleFileReader.java:259) at uk.me.parabola.mkgmap.osmstyle.RuleFileReader.rearrangeExpression(RuleFileReader.java:139) at uk.me.parabola.mkgmap.osmstyle.RuleFileReader.rearrangeExpression(RuleFileReader.java:144) at uk.me.parabola.mkgmap.osmstyle.RuleFileReader.saveRule(RuleFileReader.java:120) at uk.me.parabola.mkgmap.osmstyle.RuleFileReader.load(RuleFileReader.java:96) at uk.me.parabola.mkgmap.osmstyle.RuleFileReader.load(RuleFileReader.java:72) at uk.me.parabola.mkgmap.osmstyle.StyleImpl.readRules(StyleImpl.java:304) at uk.me.parabola.mkgmap.osmstyle.StyleImpl.<init>(StyleImpl.java:146) at uk.me.parabola.mkgmap.main.Main.listStyles(Main.java:289) at uk.me.parabola.mkgmap.main.Main.processOption(Main.java:250) at uk.me.parabola.mkgmap.CommandArgsReader$CommandOption.processArg(CommandArgsReader.java:297) at uk.me.parabola.mkgmap.CommandArgsReader.readArgs(CommandArgsReader.java:123) at uk.me.parabola.mkgmap.main.Main.main(Main.java:114)

On 28/09/12 13:41, aighes wrote:
I've got a NPE while testing my style-file ( http://www.aighes.de/data/rrk_style.zip ).
That file doesn't exist for me.
Any guesses were the fault could be? Maybe a better errormessage could be generated by mkgmap in this case?
I'm guessing you have something like: a=b | c [0x1 ] In other words you have a bare tag name without any operation. If you apply the attached patch, it will show you the line number of the problem, if it is due to this. The message is somewhat cryptic, so will need to do something about that. Also the similar case: a=b & c [0x2 ] does not give an error (the 'c' bit is always regarded as true I think) but it probably should. ..Steve

Am 28.09.2012 15:48, schrieb Steve Ratcliffe:
On 28/09/12 13:41, aighes wrote:
I've got a NPE while testing my style-file ( http://www.aighes.de/data/rrk_style.zip ).
That file doesn't exist for me. Should work now, sorry.
Any guesses were the fault could be? Maybe a better errormessage could be generated by mkgmap in this case?
I'm guessing you have something like:
a=b | c [0x1 ]
In other words you have a bare tag name without any operation.
If you apply the attached patch, it will show you the line number of the problem, if it is due to this.
The message is somewhat cryptic, so will need to do something about that.
Also the similar case:
a=b & c [0x2 ]
does not give an error (the 'c' bit is always regarded as true I think) but it probably should.
..Steve Thanks for that, I found the problematic part.
Henning
participants (2)
-
aighes
-
Steve Ratcliffe