38 lines
1.8 KiB
Diff
38 lines
1.8 KiB
Diff
--- OpenShadingLanguage-Release-1.8.9/src/liboslcomp/oslcomp.cpp.orig 2017-05-31 08:14:33.000000000 +0300
|
|
+++ OpenShadingLanguage-Release-1.8.9/src/liboslcomp/oslcomp.cpp 2017-06-19 11:08:15.725143800 +0300
|
|
@@ -202,8 +202,8 @@
|
|
std::string &result)
|
|
{
|
|
// Read file contents into a string
|
|
- std::ifstream instream;
|
|
- OIIO::Filesystem::open(instream, filename);
|
|
+ OIIO::ifstream instream;
|
|
+ OIIO::Filesystem::open(instream, OIIO::string_view(filename.c_str()));
|
|
if (! instream.is_open()) {
|
|
error (ustring(filename), 0, "Could not open \"%s\"\n", filename.c_str());
|
|
return false;
|
|
@@ -558,8 +558,8 @@
|
|
if (m_output_filename.size() == 0)
|
|
m_output_filename = default_output_filename ();
|
|
|
|
- std::ofstream oso_output;
|
|
- OIIO::Filesystem::open (oso_output, m_output_filename);
|
|
+ OIIO::ofstream oso_output;
|
|
+ OIIO::Filesystem::open (oso_output, OIIO::string_view(m_output_filename.c_str()));
|
|
if (! oso_output.good()) {
|
|
error (ustring(), 0, "Could not open \"%s\"",
|
|
m_output_filename.c_str());
|
|
--- OpenShadingLanguage-Release-1.8.9/src/liboslexec/shadingsys.cpp.orig 2017-05-31 08:14:33.000000000 +0300
|
|
+++ OpenShadingLanguage-Release-1.8.9/src/liboslexec/shadingsys.cpp 2017-06-19 11:10:14.683198900 +0300
|
|
@@ -2912,8 +2916,8 @@
|
|
|
|
bool ok = true;
|
|
std::string groupfilename = tmpdir + "/shadergroup";
|
|
- std::ofstream groupfile;
|
|
- OIIO::Filesystem::open(groupfile, groupfilename);
|
|
+ OIIO::ofstream groupfile;
|
|
+ OIIO::Filesystem::open(groupfile, OIIO::string_view(groupfilename.c_str()));
|
|
if (groupfile.good()) {
|
|
groupfile << group->serialize();
|
|
groupfile.close ();
|