fixed a bug that prevented gdf files from being written under some circumstances.
git-svn-id: https://libgdf.svn.sourceforge.net/svnroot/libgdf/trunk@41 00a3b082-7228-46c3-a6fa-0e10d54cf57f
Martin Billinger
13 years ago
75 | 75 | } |
76 | 76 | } |
77 | 77 | |
78 | m_file.clear( ); | |
79 | ||
78 | 80 | m_file.open( m_filename.c_str(), std::ios_base::out | std::ios_base::binary | std::ios_base::trunc ); |
81 | ||
82 | if( m_file.fail() ) | |
83 | { | |
84 | throw std::invalid_argument( "Error opening file for writing." ); | |
85 | } | |
79 | 86 | |
80 | 87 | m_eventbuffermemory = flags & writer_ev_memory; |
81 | 88 | if( m_eventbuffermemory ) |