Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Cannot use the dump HPROF file function

Tags:

android

I want to track the memory leaks of my application. But when I want to press the dump HPROF file button from the DDMS, I get an error message saying that: "hprof: can't open /sdcard/com.google.android.apps.uploader.hprof-hptemp: Permission denied." How can I fix this?

like image 792
Gratzi Avatar asked Apr 04 '11 09:04

Gratzi


1 Answers

Yes.

Connect to your emulator/device using ADB.

Then make the catalog world writable, using chmod 777

You can also add the permission WRITE_EXTERNAL_STORAGE to your manifest file.

Read the instructions here: http://www.netmite.com/android/mydroid/2.0/dalvik/docs/heap-profiling.html

like image 133
DKIT Avatar answered Sep 24 '22 20:09

DKIT