From e98953a5a563648a69b6cb8535d1f27febeec887 Mon Sep 17 00:00:00 2001 From: Cheng Zhao Date: Fri, 27 Feb 2015 12:21:19 -0800 Subject: [PATCH] win: Fix calling FILE_PATH_LITERAL for variable, fixes #1143 --- atom/common/node_bindings.cc | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/atom/common/node_bindings.cc b/atom/common/node_bindings.cc index f98aaad81281..5efdc0b00e67 100644 --- a/atom/common/node_bindings.cc +++ b/atom/common/node_bindings.cc @@ -174,11 +174,12 @@ node::Environment* NodeBindings::CreateEnvironment( #endif // Feed node the path to initialization script. - const char* process_type = is_browser_ ? "browser" : "renderer"; + base::FilePath::StringType process_type = is_browser_ ? + FILE_PATH_LITERAL("browser") : FILE_PATH_LITERAL("renderer"); base::FilePath resources_path = GetResourcesPath(command_line, is_browser_); base::FilePath script_path = resources_path.Append(FILE_PATH_LITERAL("atom.asar")) - .Append(FILE_PATH_LITERAL(process_type)) + .Append(process_type) .Append(FILE_PATH_LITERAL("lib")) .Append(FILE_PATH_LITERAL("init.js")); std::string script_path_str = script_path.AsUTF8Unsafe();