Frameworks/base: Fix two warnings in cmds
Change-Id: Ifb9c7fb7a2d28c13010ddc186bea5f5f0daefb4a
This commit is contained in:
@@ -75,7 +75,7 @@ static int perform_list(const char* filename)
|
||||
size_t dataSize;
|
||||
err = reader.ReadEntityHeader(&key, &dataSize);
|
||||
if (err == 0) {
|
||||
printf(" entity: %s (%d bytes)\n", key.string(), dataSize);
|
||||
printf(" entity: %s (%zu bytes)\n", key.string(), dataSize);
|
||||
} else {
|
||||
printf(" Error reading entity header\n");
|
||||
}
|
||||
|
||||
@@ -78,7 +78,7 @@ fail:
|
||||
if (fstat(idmap_fd, &st) == -1) {
|
||||
return true;
|
||||
}
|
||||
if (st.st_size < N) {
|
||||
if (st.st_size < static_cast<off_t>(N)) {
|
||||
// file is empty or corrupt
|
||||
return true;
|
||||
}
|
||||
|
||||
@@ -1773,9 +1773,7 @@ public:
|
||||
const char* targetPath, const char* overlayPath,
|
||||
void** outData, size_t* outSize) const;
|
||||
|
||||
enum {
|
||||
IDMAP_HEADER_SIZE_BYTES = 4 * sizeof(uint32_t) + 2 * 256,
|
||||
};
|
||||
static const size_t IDMAP_HEADER_SIZE_BYTES = 4 * sizeof(uint32_t) + 2 * 256;
|
||||
|
||||
// Retrieve idmap meta-data.
|
||||
//
|
||||
|
||||
Reference in New Issue
Block a user