FGPath path(globals->get_fg_root());
path.append(hud_path);
- ifstream input(path.c_str());
+ ifstream input(path.c_str(), ios::binary);
if (!input.good())
{
FG_LOG(FG_INPUT, FG_ALERT,
path.append("Huds/Minimal/default.xml");
- ifstream input(path.c_str());
+ ifstream input(path.c_str(), ios::binary);
if (!input.good()) {
FG_LOG(FG_INPUT, FG_ALERT,
"Cannot read Hud configuration from " << path.str());
FGPanel * panel = 0;
FGPath path(globals->get_fg_root());
path.append(relative_path);
- ifstream input(path.c_str());
+ ifstream input(path.c_str(), ios::binary);
if (!input.good()) {
FG_LOG(FG_INPUT, FG_ALERT,
"Cannot read panel configuration from " << path.str());
char *s;
SaveDialogInput->getValue(&s);
- ofstream output(s);
+ ofstream output(s, ios::binary);
cout << saveFile << endl;
if (output.good() && fgSaveFlight(output)) {
output.close();
char *l;
LoadDialogInput->getValue(&l);
- ifstream input(l);
+ ifstream input(l, ios::binary);
if (input.good() && fgLoadFlight(input)) {
input.close();
mkDialog("Loaded flight");
FG_LOG( FG_INPUT, FG_DEBUG, " SHIFTED" );
switch (k) {
case GLUT_KEY_F1: {
- ifstream input("fgfs.sav");
+ ifstream input("fgfs.sav", ios::binary);
if (input.good() && fgLoadFlight(input)) {
input.close();
FG_LOG(FG_INPUT, FG_INFO, "Restored flight from fgfs.sav");
case GLUT_KEY_F2: {
FG_LOG(FG_INPUT, FG_INFO, "Saving flight");
cerr << "Opening output stream" << endl;
- ofstream output("fgfs.sav");
+ ofstream output("fgfs.sav", ios::binary);
cerr << "output stream opened" << endl;
if (output.good() && fgSaveFlight(output)) {
output.close();