Merge "Use uintptr_t for cast pointer to integer."
diff --git a/tools/jdwpspy/Main.cpp b/tools/jdwpspy/Main.cpp
index 0f68d52..b53f99b 100644
--- a/tools/jdwpspy/Main.cpp
+++ b/tools/jdwpspy/Main.cpp
@@ -7,6 +7,7 @@
#include "Common.h"
#include <stdlib.h>
#include <stdio.h>
+#include <stdint.h>
#include <string.h>
#include <assert.h>
#include <ctype.h>
@@ -35,7 +36,7 @@
{
const unsigned char* addr = reinterpret_cast<const unsigned char*>(vaddr);
char out[77]; /* exact fit */
- unsigned int offset; /* offset to show while printing */
+ uintptr_t offset; /* offset to show while printing */
char* hex;
char* asc;
int gap;
@@ -43,7 +44,7 @@
if (mode == kHexDumpLocal)
offset = 0;
else
- offset = (int) addr;
+ offset = (uintptr_t) addr;
memset(out, ' ', sizeof(out)-1);
out[8] = ':';