android.permission.ACCESS_DOWNLOAD_MANAGER has protection level
signatureOrSystem.  This means you can't just put the "uses" clause in
your manifest.  The application has to either be signed by the same
certificate as Download Manager, or it must be loaded on the /system
partition.  You can read about this at
http://developer.android.com/guide/topics/manifest/permission-element.html

Hod

On Jul 14, 12:07 am, Isis <[email protected]> wrote:
> Hi All,
>          I want to delete Downloads provider data. And I have added
> permission in AndroidManifest.xml,  But it doesn't work, the log gave
> me a pid and an uid, I guess the problem is caused by these two ids.If
> it's true, what can I do  to solve this problem.
>
> AndroidManifest.xml as follows:
> ...
> <uses-permission
> android:name="android.permission.ACCESS_DOWNLOAD_MANAGER" />
>     <uses-permission
> android:name="android.permission.ACCESS_DOWNLOAD_MANAGER_ADVANCED"/>
> ...
>
> Java code as follows:
> ...
> ContentResolver resolver = context.getContentResolver();
> resolver.delete(DownLoads.URI, null, null);
> ...
>
> Log as follows:
> ...
> 07-07 13:59:10.038: ERROR/ContentProvider(726):
> java.lang.SecurityException: Permission Denial: writing
> com.android.providers.downloads.DownloadProvider uri 
> content://downloads/download
> from pid=1714, uid=10085 requires
> android.permission.ACCESS_DOWNLOAD_MANAGER
> ...
>
> Any suggestion or best an example is greatly appreciated.

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to