-4

I imported an old eclipse adt project into android studio; it's a simple client that open a socket toward a local server but when i run it, android studio generate a "Java.net.SocketException permission denied". I'm sure that the code works because from eclipse it works. So there is a method can I use to refresh the manifest or to say to android studio to update it ? I tried to do a clean project but nothing.

My manifest file is the following:

<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.example.client" >

<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE"/>
<uses-permission android:name="ANDROID.PERMISSION.INTERNET"/>

<application
    android:allowBackup="true"
    android:icon="@mipmap/ic_launcher"
    android:label="@string/app_name"
    android:theme="@style/AppTheme" >
    <activity
        android:name=".MainActivity"
        android:label="@string/app_name" >
        <intent-filter>
            <action android:name="android.intent.action.MAIN" />

            <category android:name="android.intent.category.LAUNCHER" />
        </intent-filter>
    </activity>
</application>

</manifest>

PROBLEM SOLVED

Using:

<uses-permission android:name="android.permission.INTERNET"/>

instead of:

<uses-permission android:name="ANDROID.PERMISSION.INTERNET"/>
scar
  • 21
  • 1
  • 5

1 Answers1

1

There's no permission named

ANDROID.PERMISSION.INTERNET

there however one named that way:

android.permission.INTERNET
Marcin Orlowski
  • 72,056
  • 11
  • 123
  • 141