在捕获音频期间代号崩溃一次

时间:2016-04-27 02:38:26

标签: android audio record codenameone

我的应用程序在以前工作的部分崩溃了:
调用Capture.captureAudio()以获取新录制的音频文件的路径 我已经在android上测试了,我得到了这个堆栈跟踪:

[EDT] 0:5:30,336 - Exception: java.lang.NullPointerException - Attempt to invoke interface method 'int android.database.Cursor.getColumnIndexOrThrow(java.lang.String)' on a null object reference
java.lang.NullPointerException: Attempt to invoke interface method 'int android.database.Cursor.getColumnIndexOrThrow(java.lang.String)' on a null object reference
at com.codename1.impl.android.AndroidImplementation.convertImageUriToFilePath(AndroidImplementation.java:5197)
at com.codename1.impl.android.AndroidImplementation.onActivityResult(AndroidImplementation.java:4936)
at com.codename1.impl.android.CodenameOneActivity$9.run(CodenameOneActivity.java:506)
at com.codename1.ui.Display.processSerialCalls(Display.java:1150)
at com.codename1.ui.Display.edtLoopImpl(Display.java:1094)
at com.codename1.ui.Display.invokeAndBlock(Display.java:1204)
at com.codename1.ui.Display.invokeAndBlock(Display.java:1242)
at com.codename1.capture.Capture.captureAudio(Capture.java:95)
at com.handover.app.taskhandlers.AudioTaskListener$AudioShowHandler.lambda$run$11(AudioTaskListener.java:86)
at com.handover.app.taskhandlers.AudioTaskListener$AudioShowHandler.access$lambda$0(AudioTaskListener.java)
at com.handover.app.taskhandlers.AudioTaskListener$AudioShowHandler$$Lambda$1.actionPerformed(Unknown Source)
at com.codename1.ui.util.EventDispatcher.fireActionSync(EventDispatcher.java:459)
at com.codename1.ui.util.EventDispatcher.fireActionEvent(EventDispatcher.java:362)
at com.codename1.ui.Button.fireActionEvent(Button.java:411)
at com.codename1.ui.Button.released(Button.java:442)
at com.codename1.ui.Button.pointerReleased(Button.java:530)
at com.codename1.ui.Form.pointerReleased(Form.java:2613)
at com.codename1.ui.Form.pointerReleased(Form.java:2549)
at com.codename1.ui.Component.pointerReleased(Component.java:3147)
at com.codename1.ui.Display.handleEvent(Display.java:2024)
at com.codename1.ui.Display.edtLoopImpl(Display.java:1066)
at com.codename1.ui.Display.invokeAndBlock(Display.java:1204)
at com.codename1.ui.Display.invokeAndBlock(Display.java:1242)
at com.codename1.ui.AnimationManager.addAnimationAndBlock(AnimationManager.java:105)
at com.codename1.ui.Container.animateHierarchy(Container.java:2465)
at com.codename1.ui.Container.animateHierarchyAndWait(Container.java:2185)
at com.handover.app.ui.components.ToastNotification.setVisible(ToastNotification.java:782)
at com.handover.app.ui.components.ToastNotification.updateStatus(ToastNotification.java:530)
at com.handover.app.ui.components.ToastNotification.removeStatus(ToastNotification.java:738)
at com.handover.app.ui.components.ToastNotification.access$700(ToastNotification.java:82)
at com.handover.app.ui.components.ToastNotification$Status.clear(ToastNotification.java:380)
at com.handover.app.ui.components.NetworkProgressIndicator.actionPerformed(NetworkProgressIndicator.java:55)
at com.codename1.ui.util.EventDispatcher.fireActionSync(EventDispatcher.java:459)
at com.codename1.ui.util.EventDispatcher.access$100(EventDispatcher.java:45)
at com.codename1.ui.util.EventDispatcher$CallbackClass.run(EventDispatcher.java:95)
at com.codename1.ui.Display.processSerialCalls(Display.java:1150)
at com.codename1.ui.Display.edtLoopImpl(Display.java:1094)
at com.codename1.ui.Display.mainEDTLoop(Display.java:995)
at com.codename1.ui.RunnableWrapper.run(RunnableWrapper.java:120)
at com.codename1.impl.CodenameOneThread$1.run(CodenameOneThread.java:60)
at java.lang.Thread.run(Thread.java:831)

已经有一段时间了,因为应用程序的这一部分经过了彻底的测试,而且我还没有完全确定哪个版本的CN1正在使用。
Capture.capturePhoto()和Capture.captureVideo()仍然按预期工作。

1 个答案:

答案 0 :(得分:1)

这应该在Android版本的当前版本中修复