From 9324f74c9b1dcbb6aae655dbb24ca05284a144df Mon Sep 17 00:00:00 2001 From: "Kevin M. Rosenberg" Date: Sun, 17 Dec 2000 22:30:09 +0000 Subject: [PATCH] r272: Added std:: naming to ios variables --- libctsim/projections.cpp | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/libctsim/projections.cpp b/libctsim/projections.cpp index edbed03..d2ab2b6 100644 --- a/libctsim/projections.cpp +++ b/libctsim/projections.cpp @@ -8,7 +8,7 @@ ** This is part of the CTSim program ** Copyright (C) 1983-2000 Kevin Rosenberg ** -** $Id: projections.cpp,v 1.32 2000/12/16 06:12:47 kevin Exp $ +** $Id: projections.cpp,v 1.33 2000/12/17 22:30:09 kevin Exp $ ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License (version 2) as @@ -307,10 +307,14 @@ Projections::read (const std::string& filename) bool Projections::read (const char* filename) { - frnetorderstream fileRead (filename, ios::in | ios::binary); - m_filename = filename; - - if (! fileRead) + m_filename = filename; +#ifdef MSVC + frnetorderstream fileRead (m_filename.c_str(), std::ios::in | std::ios::binary); +#else + frnetorderstream fileRead (m_filename.c_str(), std::ios::in | std::ios::binary | std::ios::nocreate); +#endif + + if (fileRead.fail()) return false; if (! headerRead (fileRead)) -- 2.34.1