FIXME: use new libdcp open_error API.
[dcpomatic.git] / src / lib / string_text_file.cc
index 869a2c96a832cf1044caff7e19463b674230aaa6..a93ba6948d8e6660835840e24512390fbc57dd7b 100644 (file)
@@ -56,7 +56,7 @@ StringTextFile::StringTextFile (shared_ptr<const StringTextFileContent> content)
        if (ext == ".stl") {
                dcp::File f(content->path(0), "rb");
                if (!f) {
-                       throw OpenFileError (f.path(), errno, OpenFileError::READ);
+                       throw OpenFileError(f.path(), f.open_error(), OpenFileError::READ);
                }
                try {
                        reader.reset(new sub::STLBinaryReader(f.get()));