Revision: 3559 Author: [email protected] Date: Thu Jan 7 04:31:45 2010 Log: Fix runtime function StringCharAt where an argument was not checked.
Review URL: http://codereview.chromium.org/523126 http://code.google.com/p/v8/source/detail?r=3559 Modified: /branches/bleeding_edge/src/runtime.cc ======================================= --- /branches/bleeding_edge/src/runtime.cc Thu Jan 7 02:25:20 2010 +++ /branches/bleeding_edge/src/runtime.cc Thu Jan 7 04:31:45 2010 @@ -1408,7 +1408,10 @@ static Object* Runtime_StringCharAt(Arguments args) { NoHandleAllocation ha; ASSERT(args.length() == 2); - return CharFromCode(Runtime_StringCharCodeAt(args)); + + CONVERT_CHECKED(String, subject, args[0]); + Object* index = args[1]; + return CharFromCode(CharCodeAt(subject, index)); }
-- v8-dev mailing list [email protected] http://groups.google.com/group/v8-dev
