Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit e57fac5e authored by android-build-team Robot's avatar android-build-team Robot
Browse files

Merge cherrypicks of [13307953, 13308437, 13309644, 13308319, 13308320,...

Merge cherrypicks of [13307953, 13308437, 13309644, 13308319, 13308320, 13307954, 13307955, 13309645, 13307572, 13307573, 13307574, 13308321, 13309664] into rvc-qpr2-release

Change-Id: I18139fb3479b7ecbb74d0298f9a48ae1c7389ddf
parents b18f2f5c e39e5544
Loading
Loading
Loading
Loading
+7 −0
Original line number Diff line number Diff line
@@ -39,6 +39,7 @@ import android.database.Cursor;
import android.database.DatabaseUtils;
import android.net.Uri;
import android.os.RemoteException;
import android.os.StrictMode;
import android.text.format.DateUtils;
import android.text.format.TimeMigrationUtils;
import android.util.Log;
@@ -2618,7 +2619,13 @@ public final class CalendarContract {
            intent.setData(ContentUris.withAppendedId(CalendarContract.CONTENT_URI, alarmTime));
            intent.putExtra(ALARM_TIME, alarmTime);
            intent.setFlags(Intent.FLAG_RECEIVER_INCLUDE_BACKGROUND);

            // Disable strict mode VM policy violations temporarily for intents that contain a
            // content URI but don't have FLAG_GRANT_READ_URI_PERMISSION.
            StrictMode.VmPolicy oldVmPolicy = StrictMode.allowVmViolations();
            PendingIntent pi = PendingIntent.getBroadcast(context, 0, intent, 0);
            StrictMode.setVmPolicy(oldVmPolicy);

            manager.setExactAndAllowWhileIdle(AlarmManager.RTC_WAKEUP, alarmTime, pi);
        }