Index: src/platform-linux.cc |
=================================================================== |
--- src/platform-linux.cc (revision 784) |
+++ src/platform-linux.cc (working copy) |
@@ -309,13 +309,14 @@ |
fclose(file_); |
} |
+ |
#ifdef ENABLE_LOGGING_AND_PROFILING |
-static unsigned StringToLongLong(char* buffer) { |
- return static_cast<unsigned>(strtoll(buffer, NULL, 16)); // NOLINT |
+static unsigned StringToLong(char* buffer) { |
+ return static_cast<unsigned>(strtol(buffer, NULL, 16)); // NOLINT |
} |
- |
#endif |
+ |
void OS::LogSharedLibraryAddresses() { |
#ifdef ENABLE_LOGGING_AND_PROFILING |
static const int MAP_LENGTH = 1024; |
@@ -328,13 +329,13 @@ |
addr_buffer[10] = 0; |
int result = read(fd, addr_buffer + 2, 8); |
if (result < 8) break; |
- unsigned start = StringToLongLong(addr_buffer); |
+ unsigned start = StringToLong(addr_buffer); |
result = read(fd, addr_buffer + 2, 1); |
if (result < 1) break; |
if (addr_buffer[2] != '-') break; |
result = read(fd, addr_buffer + 2, 8); |
if (result < 8) break; |
- unsigned end = StringToLongLong(addr_buffer); |
+ unsigned end = StringToLong(addr_buffer); |
char buffer[MAP_LENGTH]; |
int bytes_read = -1; |
do { |