Merge "Restrict adding the implicit READ_URI grant flag." into udc-dev
This commit is contained in:
committed by
Android (Google) Code Review
commit
0bb91e1d18
@@ -12349,7 +12349,9 @@ public class Intent implements Parcelable, Cloneable {
|
||||
null, new String[] { getType() },
|
||||
new ClipData.Item(text, htmlText, null, stream));
|
||||
setClipData(clipData);
|
||||
addFlags(FLAG_GRANT_READ_URI_PERMISSION);
|
||||
if (stream != null) {
|
||||
addFlags(FLAG_GRANT_READ_URI_PERMISSION);
|
||||
}
|
||||
return true;
|
||||
}
|
||||
} catch (ClassCastException e) {
|
||||
@@ -12388,7 +12390,9 @@ public class Intent implements Parcelable, Cloneable {
|
||||
}
|
||||
|
||||
setClipData(clipData);
|
||||
addFlags(FLAG_GRANT_READ_URI_PERMISSION);
|
||||
if (streams != null) {
|
||||
addFlags(FLAG_GRANT_READ_URI_PERMISSION);
|
||||
}
|
||||
return true;
|
||||
}
|
||||
} catch (ClassCastException e) {
|
||||
|
||||
Reference in New Issue
Block a user