X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=src%2Fv8%2Fsamples%2Flineprocessor.cc;h=9b627f3019c656cab8663308aedd5fe2b64e3b1f;hb=4a1a0bdd01eef90b0826a0e761d3379d3715c10f;hp=edb0ba0a1e62ab01f3e32528eebe6196e679ff52;hpb=b1be5ca53587d23e7aeb77b26861fdc0a181ffd8;p=platform%2Fframework%2Fweb%2Fcrosswalk.git diff --git a/src/v8/samples/lineprocessor.cc b/src/v8/samples/lineprocessor.cc index edb0ba0..9b627f3 100644 --- a/src/v8/samples/lineprocessor.cc +++ b/src/v8/samples/lineprocessor.cc @@ -25,14 +25,15 @@ // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -#include +#include -#include +#include +#include #include -#include #include #include +#include /** * This sample program should demonstrate certain aspects of debugging @@ -254,8 +255,12 @@ bool RunCppCycle(v8::Handle script, int main(int argc, char* argv[]) { v8::V8::InitializeICU(); + v8::Platform* platform = v8::platform::CreateDefaultPlatform(); + v8::V8::InitializePlatform(platform); int result = RunMain(argc, argv); v8::V8::Dispose(); + v8::V8::ShutdownPlatform(); + delete platform; return result; } @@ -300,7 +305,7 @@ void ReportException(v8::Isolate* isolate, v8::TryCatch* try_catch) { printf("%s\n", exception_string); } else { // Print (filename):(line number): (message). - v8::String::Utf8Value filename(message->GetScriptResourceName()); + v8::String::Utf8Value filename(message->GetScriptOrigin().ResourceName()); const char* filename_string = ToCString(filename); int linenum = message->GetLineNumber(); printf("%s:%i: %s\n", filename_string, linenum, exception_string);