diff options
author | Colin Cross <ccross@android.com> | 2014-02-06 02:30:31 +0100 |
---|---|---|
committer | Colin Cross <ccross@android.com> | 2014-02-06 02:34:45 +0100 |
commit | 92cdf9c37225c6f76b96c8f137896cd9e9015bbd (patch) | |
tree | dbf70c82b2e8d48e6d6515689b47cfe327f71b49 | |
parent | Merge "minadbd: remove dead code" (diff) | |
download | android_bootable_recovery-92cdf9c37225c6f76b96c8f137896cd9e9015bbd.tar android_bootable_recovery-92cdf9c37225c6f76b96c8f137896cd9e9015bbd.tar.gz android_bootable_recovery-92cdf9c37225c6f76b96c8f137896cd9e9015bbd.tar.bz2 android_bootable_recovery-92cdf9c37225c6f76b96c8f137896cd9e9015bbd.tar.lz android_bootable_recovery-92cdf9c37225c6f76b96c8f137896cd9e9015bbd.tar.xz android_bootable_recovery-92cdf9c37225c6f76b96c8f137896cd9e9015bbd.tar.zst android_bootable_recovery-92cdf9c37225c6f76b96c8f137896cd9e9015bbd.zip |
-rw-r--r-- | minadbd/services.c | 4 | ||||
-rw-r--r-- | minui/graphics.c | 2 | ||||
-rw-r--r-- | minzip/Zip.c | 4 |
3 files changed, 5 insertions, 5 deletions
diff --git a/minadbd/services.c b/minadbd/services.c index aef37f7e4..4698528ef 100644 --- a/minadbd/services.c +++ b/minadbd/services.c @@ -46,7 +46,7 @@ void *service_bootstrap_func(void *x) static void sideload_service(int s, void *cookie) { unsigned char buf[4096]; - unsigned count = (unsigned) cookie; + unsigned count = (unsigned)(uintptr_t)cookie; int fd; fprintf(stderr, "sideload_service invoked\n"); @@ -149,7 +149,7 @@ int service_to_fd(const char *name) int ret = -1; if (!strncmp(name, "sideload:", 9)) { - ret = create_service_thread(sideload_service, (void*) atoi(name + 9)); + ret = create_service_thread(sideload_service, (void*)(uintptr_t)atoi(name + 9)); #if 0 } else if(!strncmp(name, "echo:", 5)){ ret = create_service_thread(echo_service, 0); diff --git a/minui/graphics.c b/minui/graphics.c index d75716531..a2014dca3 100644 --- a/minui/graphics.c +++ b/minui/graphics.c @@ -157,7 +157,7 @@ static int get_framebuffer(GGLSurface *fb) fb->width = vi.xres; fb->height = vi.yres; fb->stride = fi.line_length/PIXEL_SIZE; - fb->data = (void*) (((unsigned) bits) + vi.yres * fi.line_length); + fb->data = (void*) (((char*) bits) + vi.yres * fi.line_length); fb->format = PIXEL_FORMAT; memset(fb->data, 0, vi.yres * fi.line_length); diff --git a/minzip/Zip.c b/minzip/Zip.c index 439e5d9cd..f4f38a9ff 100644 --- a/minzip/Zip.c +++ b/minzip/Zip.c @@ -772,7 +772,7 @@ bool mzReadZipEntry(const ZipArchive* pArchive, const ZipEntry* pEntry, static bool writeProcessFunction(const unsigned char *data, int dataLen, void *cookie) { - int fd = (int)cookie; + int fd = (int)(intptr_t)cookie; ssize_t soFar = 0; while (true) { @@ -802,7 +802,7 @@ bool mzExtractZipEntryToFile(const ZipArchive *pArchive, const ZipEntry *pEntry, int fd) { bool ret = mzProcessZipEntryContents(pArchive, pEntry, writeProcessFunction, - (void*)fd); + (void*)(intptr_t)fd); if (!ret) { LOGE("Can't extract entry to file.\n"); return false; |