如何调试空指针异常 [英] How to debug a null pointer exception

查看:124
本文介绍了如何调试空指针异常的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

你好,

尝试制作hangman应用程序时收到以下错误消息.请在这里帮助我.

Hello,

I got the following error message while trying to make a hangman app . Please help me out here.

Running in the identified_third_party security domain
java.lang.NullPointerException
	at hangman_game.hangman_game.gamevariables(+14)
	at hangman_game.hangman_game.process(+4)
	at hangman_game.hangman_game.commandAction(+12)
	at javax.microedition.lcdui.Display$DisplayAccessor.commandAction(+282)
	at javax.microedition.lcdui.Display$DisplayManagerImpl.commandAction(+10)
	at com.sun.midp.lcdui.DefaultEventHandler.commandEvent(+68)
	at com.sun.midp.lcdui.AutomatedEventHandler.commandEvent(+47)
	at com.sun.midp.lcdui.DefaultEventHandler$QueuedEventHandler.handleVmEvent(+186)
	at com.sun.midp.lcdui.DefaultEventHandler$QueuedEventHandler.run(+57)

推荐答案

DisplayAccessor.commandAction(+282) 在javax.microedition.lcdui.Display
DisplayAccessor.commandAction(+282) at javax.microedition.lcdui.Display


DisplayManagerImpl.commandAction(+10) 在com.sun.midp.lcdui.DefaultEventHandler.commandEvent(+68) 在com.sun.midp.lcdui.AutomatedEventHandler.commandEvent(+47) 在com.sun.midp.lcdui.DefaultEventHandler上
DisplayManagerImpl.commandAction(+10) at com.sun.midp.lcdui.DefaultEventHandler.commandEvent(+68) at com.sun.midp.lcdui.AutomatedEventHandler.commandEvent(+47) at com.sun.midp.lcdui.DefaultEventHandler


QueuedEventHandler.handleVmEvent(+186) 在com.sun.midp.lcdui.DefaultEventHandler
QueuedEventHandler.handleVmEvent(+186) at com.sun.midp.lcdui.DefaultEventHandler


这篇关于如何调试空指针异常的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆