diff options
Diffstat (limited to 'o3d/import')
-rw-r--r-- | o3d/import/cross/collada.cc | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/o3d/import/cross/collada.cc b/o3d/import/cross/collada.cc index 7de80af..562641f 100644 --- a/o3d/import/cross/collada.cc +++ b/o3d/import/cross/collada.cc @@ -534,7 +534,15 @@ bool ConvertCgToGlsl(const FilePath& converter, String* effect_string) { #endif cmd_line.AppendLooseValue(L"-i"); - cmd_line.AppendLooseValue(o3d::FilePathToWide(temporary_file_name)); + std::wstring temporary_file_string = + o3d::FilePathToWide(temporary_file_name); +#if defined(OS_WIN) + // Quote to be safe. Note that this breaks on POSIX platforms. + std::wstring quote(L"\""); + temporary_file_string = + quote + temporary_file_string + quote; +#endif + cmd_line.AppendLooseValue(temporary_file_string); bool rc = ::base::GetAppOutput(cmd_line, effect_string); file_util::Delete(temporary_file_name, false); |