Menu

#617 NPE in "menu" GpsMid 0.8

HEAD
open
nobody
5
2012-08-29
2012-08-29
sfdivan
No

Start GpsMid-0.8 either in WTK emulator (default settings, midsize or full builds at least) or on real device (Samsung B2710 in my case), allow and accept stuff, click menu button.
Whoops "In Trace.commandAction java.lang.NullPointerException: null" and no menu appears.

v0.7.7 works fine.

Ok, I did manage to track it down, the culprit is 9a19312338131a07827a557a2f430b2785f9fd23 commit (http://gpsmid.git.sourceforge.net/git/gitweb.cgi?p=gpsmid/GpsMid;a=blobdiff;f=src/de/ueller/gpsmid/ui/TraceIconMenu.java;h=b1dbfe90a2f0b3852573e2e9cc4e08b4111209d5;hp=4d27275f02d02e1f8a2ed41b36bc3886ab1adf0c;hb=9a19312338131a07827a557a2f430b2785f9fd23;hpb=627d52fcf96a1d0120bad69b7ffda3171bbd05e7)
iconHelpOnlineTouch == null if !hasPointerEvents (my phone isn't a touch one)
but the call is done
iconHelpOnlineTouch.makeImageGreyed();
with check only for !polish.api.online (not using a connected build)

Moreover, full-connected build gives NPE too, a few lines later
the same call is performed, guarded by
if (!Configuration.getCfgBitState(Configuration.CFGBIT_INTERNET_ACCESS)) { (no idea what it is)

Sorry for not having a patch - have not got myself familiar with vcs and build stuff for GpsMid, looks like it's not that trivial.

Discussion

  • Jyrki Kuoppala

    Jyrki Kuoppala - 2012-08-29

    Thanks, committed a fix.

     
  • Jyrki Kuoppala

    Jyrki Kuoppala - 2012-08-29

    Can repeat the bug also on the Nokia E72 with full-connected when I switch the menu option for internet access off in GpsMid. Trouble is now I can't get to switch internet access back on :-) Well, guess I'll have to install the fixed version.

     
  • Jyrki Kuoppala

    Jyrki Kuoppala - 2012-08-29

    If I understand correctly this is quite a wide-impact bug, affecting all non-touch devices which have internet access disabled either by target selection or by GpsMid UI. Looks like 0.8.1 shouldn't be too far away.

     

Log in to post a comment.