summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorYing Wang <wangying@google.com>2014-05-17 01:31:28 +0000
committerGerrit Code Review <noreply-gerritcodereview@google.com>2014-05-17 01:31:29 +0000
commit770cd7c7e7c18a657f233d86aeecb1d9f3091449 (patch)
tree33bae527c2afd7ba6719c1488ed125f0e0163a60
parentc4afc19236ae7253acc3266b4ca8515473e9c7cc (diff)
parentcf86e2f85d98ed10cf5e0672e41631f6ea7e3e34 (diff)
downloadsystem_core-770cd7c7e7c18a657f233d86aeecb1d9f3091449.zip
system_core-770cd7c7e7c18a657f233d86aeecb1d9f3091449.tar.gz
system_core-770cd7c7e7c18a657f233d86aeecb1d9f3091449.tar.bz2
Merge "Fix host 64-bit build."
-rw-r--r--fastboot/fastboot.c3
-rw-r--r--libziparchive/zip_archive_test.cc4
2 files changed, 4 insertions, 3 deletions
diff --git a/fastboot/fastboot.c b/fastboot/fastboot.c
index 3a140ab..9c04c21 100644
--- a/fastboot/fastboot.c
+++ b/fastboot/fastboot.c
@@ -32,6 +32,7 @@
#include <errno.h>
#include <fcntl.h>
#include <getopt.h>
+#include <inttypes.h>
#include <limits.h>
#include <stdbool.h>
#include <stdint.h>
@@ -576,7 +577,7 @@ static int64_t get_target_sparse_limit(struct usb_handle *usb)
if (!status) {
limit = strtoul(response, NULL, 0);
if (limit > 0) {
- fprintf(stderr, "target reported max download size of %lld bytes\n",
+ fprintf(stderr, "target reported max download size of %" PRId64 " bytes\n",
limit);
}
}
diff --git a/libziparchive/zip_archive_test.cc b/libziparchive/zip_archive_test.cc
index 3082216..2eb9318 100644
--- a/libziparchive/zip_archive_test.cc
+++ b/libziparchive/zip_archive_test.cc
@@ -209,7 +209,8 @@ TEST(ziparchive, ExtractToFile) {
sizeof(kATxtContents)));
// Assert that the total length of the file is sane
- ASSERT_EQ(data_size + sizeof(kATxtContents), lseek64(fd, 0, SEEK_END));
+ ASSERT_EQ(data_size + static_cast<ssize_t>(sizeof(kATxtContents)),
+ lseek64(fd, 0, SEEK_END));
close(fd);
}
@@ -247,4 +248,3 @@ int main(int argc, char** argv) {
return RUN_ALL_TESTS();
}
-