summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Qiu <zqiu@google.com>2016-12-12 13:56:48 -0800
committerAdam Seaton <aseaton@google.com>2017-01-20 00:10:51 +0000
commitab23d798ff74a2f2a6e1568292785d879b5a418b (patch)
treedc09e1810df4503552253ad27ec3ae1a3569e81b
parent4da98e32a7c53663b1af4d979b27df214a3d3b46 (diff)
downloadwifi-nougat-mr1-cts-release.tar.gz
Fix merge conflict into nyc-mr1-security release branches It is the caller's responsibility for deleting configuration files. This avoids the ConfigBuilder from deleting arbitrary files (specified by URI) pass-in by the callers. Bug: 33178389 Test: Verify Passpoint Configuration installation works using Shamu Change-Id: I54803dc711ede98a1ec1259077522032c543dca1
-rw-r--r--service/java/com/android/server/wifi/configparse/ConfigBuilder.java10
1 files changed, 0 insertions, 10 deletions
diff --git a/service/java/com/android/server/wifi/configparse/ConfigBuilder.java b/service/java/com/android/server/wifi/configparse/ConfigBuilder.java
index 9bcfddbb6..ad0165e4c 100644
--- a/service/java/com/android/server/wifi/configparse/ConfigBuilder.java
+++ b/service/java/com/android/server/wifi/configparse/ConfigBuilder.java
@@ -54,8 +54,6 @@ public class ConfigBuilder {
byte[] b64 = Base64.decode(new String(data, StandardCharsets.ISO_8859_1), Base64.DEFAULT);
Log.d(TAG, "Decoded: " + b64.length + " bytes.");
- dropFile(Uri.parse(uriString), context);
-
MIMEContainer mimeContainer = new
MIMEContainer(new LineNumberReader(
new InputStreamReader(new ByteArrayInputStream(b64), StandardCharsets.ISO_8859_1)),
@@ -79,14 +77,6 @@ public class ConfigBuilder {
return parse(inner);
}
- private static void dropFile(Uri uri, Context context) {
- if (DocumentsContract.isDocumentUri(context, uri)) {
- DocumentsContract.deleteDocument(context.getContentResolver(), uri);
- } else {
- context.getContentResolver().delete(uri, null, null);
- }
- }
-
private static WifiConfiguration parse(MIMEContainer root)
throws IOException, GeneralSecurityException, SAXException {