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

Commit 568bc323 authored by Joe Onorato's avatar Joe Onorato
Browse files

Better (and less) logging from backup.

parent 12a4da32
Loading
Loading
Loading
Loading
+4 −1
Original line number Diff line number Diff line
@@ -107,7 +107,10 @@ BackupDataWriter::WriteEntityHeader(const String8& key, size_t dataSize)
    } else {
        k = key;
    }
    LOGD("m_keyPrefix=%s key=%s k=%s", m_keyPrefix.string(), key.string(), k.string());
    if (true) {
        LOGD("Writing entity: prefix='%s' key='%s' dataSize=%d", m_keyPrefix.string(), key.string(),
                dataSize);
    }

    entity_header_v1 header;
    ssize_t keyLen;
+5 −2
Original line number Diff line number Diff line
@@ -68,11 +68,15 @@ struct file_metadata_v1 {

const static int CURRENT_METADATA_VERSION = 1;

#if 1 // TEST_BACKUP_HELPERS
#if 1
#define LOGP(f, x...)
#else
#if TEST_BACKUP_HELPERS
#define LOGP(f, x...) printf(f "\n", x)
#else
#define LOGP(x...) LOGD(x)
#endif
#endif

const static int ROUND_UP[4] = { 0, 3, 2, 1 };

@@ -349,7 +353,6 @@ back_up_files(int oldSnapshotFD, BackupDataWriter* dataStream, int newSnapshotFD

        err = stat(file, &st);
        if (err != 0) {
            LOGW("Error stating file %s", file);
            r.deleted = true;
        } else {
            r.deleted = false;