Commit 49e29575 authored by Tom Taylor's avatar Tom Taylor Committed by Android Git Automerger
Browse files

am 21cf95e7: Don\'t allow clients to update or insert _data column data

* commit '21cf95e7':
  Don't allow clients to update or insert _data column data
parents 8d4bb29c 21cf95e7
......@@ -266,6 +266,10 @@ public class MmsProvider extends ContentProvider {
@Override
public Uri insert(Uri uri, ContentValues values) {
// Don't let anyone insert anything with the _data column
if (values != null && values.containsKey(Part._DATA)) {
return null;
}
int msgBox = Mms.MESSAGE_BOX_ALL;
boolean notify = true;
......@@ -680,6 +684,10 @@ public class MmsProvider extends ContentProvider {
@Override
public int update(Uri uri, ContentValues values,
String selection, String[] selectionArgs) {
// Don't let anyone update the _data column
if (values != null && values.containsKey(Part._DATA)) {
return 0;
}
int match = sURLMatcher.match(uri);
if (LOCAL_LOGV) {
Log.v(TAG, "Update uri=" + uri + ", match=" + match);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment