diff options
author | Etan Cohen <etancohen@google.com> | 2017-03-20 11:35:55 -0700 |
---|---|---|
committer | Etan Cohen <etancohen@google.com> | 2017-03-28 11:42:12 -0700 |
commit | 16b00750e1d3c41ce9b4ccae9f07e0586e8ca2d0 (patch) | |
tree | c320c1a121892beb0601e8ae852fa1cbe32ff5f8 /service | |
parent | 331184d17817a25263e2e731f87a3bc68bc831ef (diff) |
[AWARE] Restrict publish/subscribe count configuration API
Public API access to publish/subscribe count removed. Enforce
restriction on service side.
Bug: 36446307
Test: unit tests and integration (sl4a) tests
Change-Id: I28edd79dcf3aa1e34f921a35c388dc0b056831d0
Diffstat (limited to 'service')
-rw-r--r-- | service/java/com/android/server/wifi/aware/WifiAwareNativeApi.java | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/service/java/com/android/server/wifi/aware/WifiAwareNativeApi.java b/service/java/com/android/server/wifi/aware/WifiAwareNativeApi.java index afe6db13a..8d99befdd 100644 --- a/service/java/com/android/server/wifi/aware/WifiAwareNativeApi.java +++ b/service/java/com/android/server/wifi/aware/WifiAwareNativeApi.java @@ -302,7 +302,7 @@ public class WifiAwareNativeApi { req.baseConfigs.sessionId = 0; req.baseConfigs.ttlSec = (short) publishConfig.mTtlSec; req.baseConfigs.discoveryWindowPeriod = 1; - req.baseConfigs.discoveryCount = (byte) publishConfig.mPublishCount; + req.baseConfigs.discoveryCount = 0; convertNativeByteArrayToArrayList(publishConfig.mServiceName, req.baseConfigs.serviceName); // TODO: what's the right value on publish? req.baseConfigs.discoveryMatchIndicator = NanMatchAlg.MATCH_ONCE; @@ -364,7 +364,7 @@ public class WifiAwareNativeApi { req.baseConfigs.sessionId = 0; req.baseConfigs.ttlSec = (short) subscribeConfig.mTtlSec; req.baseConfigs.discoveryWindowPeriod = 1; - req.baseConfigs.discoveryCount = (byte) subscribeConfig.mSubscribeCount; + req.baseConfigs.discoveryCount = 0; convertNativeByteArrayToArrayList(subscribeConfig.mServiceName, req.baseConfigs.serviceName); req.baseConfigs.discoveryMatchIndicator = subscribeConfig.mMatchStyle; |