2016-05-16 77 views
2

我在React Native中创建了一个在iOS中正常工作的应用程序。我已将代码复制到Android的Android部分,并分离出特定于平台的组件。当我点击某个组件时,该应用程序会崩溃,并显示“不幸已停止”。Genymotion:“不幸<app>已停止”

没有日志,控制台没有错误,什么都没有。我寻找什么,我可以在哪里看?日志?代码中的某处?

在〜/ genymotion日志/谷歌Nexus 6 < ...> - logcat.txt,我看到以下内容:

05-15 23:50:14.379 D/OpenGLRenderer( 620): Use EGL_SWAP_BEHAVIOR_PRESERVED: true 
05-15 23:50:14.380 D/Atlas ( 620): Validating map... 
05-15 23:50:14.429 I/OpenGLRenderer( 620): Initialized EGL, version 1.4 
05-15 23:50:14.429 D/  ( 620): HostConnection::get() New Host Connection established 0xaf31ca40, tid 1876 
05-15 23:50:14.463 D/OpenGLRenderer( 620): Enabling debug mode 0 
05-15 23:50:14.489 W/EGL_emulation( 620): eglSurfaceAttrib not implemented 
05-15 23:50:14.490 W/OpenGLRenderer( 620): Failed to set EGL_SWAP_BEHAVIOR on surface 0x9e45dfc0, error=EGL_SUCCESS 
05-15 23:50:14.490 W/EGL_emulation( 941): eglSurfaceAttrib not implemented 
05-15 23:50:14.490 W/OpenGLRenderer( 941): Failed to set EGL_SWAP_BEHAVIOR on surface 0xb43e44a0, error=EGL_SUCCESS 
05-15 23:50:14.952 I/ActivityManager( 620): Killing 1492:com.android.onetimeinitializer/u0a10 (adj 15): empty #17 
05-15 23:50:15.219 W/OpenGLRenderer( 941): Incorrectly called buildLayer on View: ShortcutAndWidgetContainer, destroying layer... 
05-15 23:50:15.440 W/ResourceType( 724): No package identifier when getting value for resource number 0x00000000 
05-15 23:50:15.442 W/PackageManager( 724): Failure retrieving resources for com.bidsmart: Resource ID #0x0 
05-15 23:50:18.400 W/AudioTrack( 620): AUDIO_OUTPUT_FLAG_FAST denied by client 
05-15 23:50:18.424 I/Process (1805): Sending signal. PID: 1805 SIG: 9 
05-15 23:50:18.463 D/OpenGLRenderer( 620): endAllStagingAnimators on 0xa1a6f780 (RippleDrawable) with handle 0xaf3be470 
05-15 23:50:18.468 I/ActivityManager( 620): Process com.bidsmart (pid 1805) has died 
05-15 23:50:18.472 W/InputMethodManagerService( 620): Got RemoteException sending setActive(false) notification to pid 1805 uid 10061 
+0

你们是不是要一个端口连接在App @Nathan海仑。 – Lampard

+0

不确定这是什么意思,真的。一个物理端口?要明确,该应用程序的作品,直到你击中其中一个组件,其中有几个嵌套。 –

+0

是@ Nathan Hyland – Lampard

回答

0

没有修复,但原因是我推着太多的数据从服务器到客户端。一旦我运行adb logcat,我得到了这个:

java.lang.OutOfMemoryError: Failed to allocate a 2470012 byte allocation with 48508 free bytes and 47KB until OOM

原来我一遍又一遍地向客户推送我的图像,直到它破裂。 iOS可以处理它,但是RN不能。

链接StackOverflow的相关话题:Android:java.lang.OutOfMemoryError: Failed to allocate a 23970828 byte allocation with 2097152 free bytes and 2MB until OOM