java.lang.SecurityException: MODE_WORLD_WRITEABLE no longer supported

5 posts / 0 new
Last post
Hesam
java.lang.SecurityException: MODE_WORLD_WRITEABLE no longer supported

Hello,

We have a legacy app that we build it few years ago. We are using mapquest-android-sdk-1.0.5.jar in our application.

Unfortunatly app is carshing and I have following log after debug. So, any help would be appreciated. Thanks.

E/AndroidRuntime: FATAL EXCEPTION: cache
            Process: com.my_company.venue, PID: 14671
            java.lang.SecurityException: MODE_WORLD_WRITEABLE no longer supported
            at android.app.ContextImpl.checkMode(ContextImpl.java:2165)
            at android.app.ContextImpl.getDir(ContextImpl.java:1983)
            at android.content.ContextWrapper.getDir(ContextWrapper.java:278)
            at com.mapquest.android.maps.FSTileCache$CacheHandler.handleMessage(FSTileCache.java:394)
            at android.os.Handler.dispatchMessage(Handler.java:102)
            at android.os.Looper.loop(Looper.java:154)
            at android.os.HandlerThread.run(HandlerThread.java:61)


MQBrianCoakley
I suspect that is due to
I suspect that is due to Android updates and the old MapQuest Android sdk isn't working well with it. That has been deprecated for some time. I don't think there will be a fix for that. I recommend using the current mobile sdks with vector maps. The Android version is here.

Hesam
Thanks MQBrianCoakley for

Thanks MQBrianCoakley for your answer.

I don't think Android update is the cause as I have not updated my emulator nor Device. I got an email from Mapquest long time ago and they said somethings are depricated. Unfortunatly, I couldn't find that email. So, Due to log, I guess this has been really depricated now.


Hesam
What I did to fix the issue

What I did to fix the issue is down grade of targetSdkVersion from 25 to 23. So, that crash did not happen again.

defaultConfig {
minSdkVersion 15
targetSdkVersion 23
}


MQBrianCoakley
Awesome. Thanks for posting
Awesome. Thanks for posting your solution!