Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(806)

Unified Diff: src/v8utils.cc

Issue 13932006: Replace OS::MemCopy with OS::MemMove (just as fast but more flexible). (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: addressed comments Created 7 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/v8utils.h ('k') | src/x64/assembler-x64.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/v8utils.cc
diff --git a/src/v8utils.cc b/src/v8utils.cc
index 58ad4e5edd5262b7dba1e67c769250e090ac3af1..c5ca846119c5d1e23dca23c67a0e3b0d5bdc3680 100644
--- a/src/v8utils.cc
+++ b/src/v8utils.cc
@@ -105,12 +105,12 @@ char* ReadLine(const char* prompt) {
char* new_result = NewArray<char>(new_len);
// Copy the existing input into the new array and set the new
// array as the result.
- memcpy(new_result, result, offset * kCharSize);
+ OS::MemCopy(new_result, result, offset * kCharSize);
DeleteArray(result);
result = new_result;
}
// Copy the newly read line into the result.
- memcpy(result + offset, line_buf, len * kCharSize);
+ OS::MemCopy(result + offset, line_buf, len * kCharSize);
offset += len;
}
ASSERT(result != NULL);
« no previous file with comments | « src/v8utils.h ('k') | src/x64/assembler-x64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698