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

Commit b481778d authored by Al Sutton's avatar Al Sutton
Browse files

Ignore No Data Changed Notifications

We're adding a "No Data Changed" notification to the framework for
K/V backups where no data has changed. LocalTransport has no use
for this notification so we'll ignore it if we see it.

Test: m -j RunBackupFrameworksServicesRoboTests
Bug: 147481066
Change-Id: Ida934f2a17367c430f3411ce1a457515c59746fd
parent 14763d14
Loading
Loading
Loading
Loading
+6 −0
Original line number Diff line number Diff line
@@ -211,6 +211,12 @@ public class LocalTransport extends BackupTransport {

    private int performBackupInternal(
            PackageInfo packageInfo, ParcelFileDescriptor data, int flags) {
        if ((flags & BackupTransport.FLAG_DATA_NOT_CHANGED) != 0) {
            // For unchanged data notifications we do nothing and tell the
            // caller everything was OK
            return BackupTransport.TRANSPORT_OK;
        }

        boolean isIncremental = (flags & FLAG_INCREMENTAL) != 0;
        boolean isNonIncremental = (flags & FLAG_NON_INCREMENTAL) != 0;