java.lang.OutOfMemoryError -Android

时间:2018-02-06 08:56:16

标签: android

java.lang.OutOfMemoryError:Failed to allocate a 1631415409byte allocation with 2474340 free bytes and 380 MB until OOM
        at com.android.volley.toolbox.DiskBasedCache.streamToBytes(DiskBasedCache.java:316)
        at com.android.volley.toolbox.DiskBasedCache.readString(DiskBasedCache.java:526)
        at com.android.volley.toolbox.DiskBasedCache.readStringStringMap(DiskBasedCache.java:548)

Mainfest.xml

  <application
        android:name=".globalexceptionhandler.MyApp"
        android:allowBackup="true"
        android:hardwareAccelerated="false"
        android:icon="@mipmap/ic_launcher"
        android:label="@string/app_name"
        android:largeHeap="true"
        android:persistent="true"
        android:supportsRtl="true"
        android:theme="@style/AppTheme">

1 个答案:

答案 0 :(得分:-1)

尝试使用最新版本的Volley。问题似乎在https://github.com/google/volley/issues/12中得到修复。

compile 'com.android.volley:volley:1.1.0'