#include <simgear/sg_inlines.h>
#include <simgear/debug/logstream.hxx>
#include <simgear/math/sg_random.h>
+#include <simgear/misc/sgstream.hxx>
#include <simgear/scene/material/mat.hxx>
#include <simgear/scene/material/matlib.hxx>
#include <simgear/structure/exception.hxx>
return false;
}
- ifstream input(validated_path.c_str());
+ sg_ifstream input(SGPath::fromUtf8(validated_path));
if (input.good() && fgLoadFlight(input)) {
input.close();
SG_LOG(SG_INPUT, SG_INFO, "Restored flight from " << file);
#include <simgear/props/props.hxx>
#include <simgear/math/sg_random.h>
#include <simgear/misc/sg_path.hxx>
+#include <simgear/misc/sgstream.hxx>
#include <simgear/misc/sg_dir.hxx>
#include <simgear/misc/SimpleMarkdown.hxx>
#include <simgear/structure/commands.hxx>
naRuntimeError(c, "parsexml(): access denied (unauthorized directory)");
return naNil();
}
- std::ifstream input(file.c_str());
+ sg_ifstream input(SGPath::fromUtf8(file));
NasalXMLVisitor visitor(c, argc, args);
try {
readXML(input, visitor);