Reputation: 10349
I written 2 apps.
First app has only service and second one has an Activity. I am starting the service in 1st app from activity in 2nd app. In Service I am modifying audio settings so, I need android.permission.MODIFY_AUDIO_SETTINGS
in manifest.
My question is in which manifest file I have to add this permission. Why I am asking because if I add this permission in Service app manifest I am getting warning Exported service does not require permission.
If anybody know it, post the solution.
Upvotes: 4
Views: 5892
Reputation: 75619
You need to add this permission to application, not service. Permissions for services are to let you limit who can access them which is something different. You need to add
<uses-permission android:name="android.permission.MODIFY_AUDIO_SETTINGS" />
to your Manifest, above <application>
block of application that does the audio settings change.
Upvotes: 4