From 2de3a5762f4c77852810d8f6de6b60aabee9a38e Mon Sep 17 00:00:00 2001 From: Dmitry Shmidt Date: Wed, 14 Aug 2013 12:59:23 -0700 Subject: wifi: Do not use prefix for p2p commands Bug: 9298955 Change-Id: I73dab83d133ab3a79cdf804764ba0583a6c9af7f Signed-off-by: Dmitry Shmidt --- wifi/java/android/net/wifi/WifiNative.java | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'wifi/java') diff --git a/wifi/java/android/net/wifi/WifiNative.java b/wifi/java/android/net/wifi/WifiNative.java index 0359076..4723cc1 100644 --- a/wifi/java/android/net/wifi/WifiNative.java +++ b/wifi/java/android/net/wifi/WifiNative.java @@ -82,8 +82,13 @@ public class WifiNative { public WifiNative(String interfaceName) { mInterfaceName = interfaceName; - mInterfacePrefix = "IFNAME=" + interfaceName + " "; mTAG = "WifiNative-" + interfaceName; + if (!interfaceName.equals("p2p0")) { + mInterfacePrefix = "IFNAME=" + interfaceName + " "; + } else { + // commands for p2p0 interface don't need prefix + mInterfacePrefix = ""; + } } public boolean connectToSupplicant() { -- cgit v1.1