//
// Open a file for gzipped writing.
//
-sg_gzofstream::sg_gzofstream( const std::string& name, ios_openmode io_mode )
+sg_gzofstream::sg_gzofstream( const SGPath& name, ios_openmode io_mode )
: ostream(&gzbuf)
{
this->open( name, io_mode );
// Open a file for gzipped writing.
//
void
-sg_gzofstream::open( const std::string& name, ios_openmode io_mode )
+sg_gzofstream::open( const SGPath& name, ios_openmode io_mode )
{
- gzbuf.open( name.c_str(), io_mode );
+ std::string ps = name.local8BitStr();
+ gzbuf.open( ps.c_str(), io_mode );
}
void
* @param name name of file
* @param io_mode file open mode(s) "or'd" together
*/
- sg_gzofstream( const std::string& name,
+ sg_gzofstream( const SGPath& name,
ios_openmode io_mode = ios_out | ios_binary );
/**
* @param name name of file
* @param io_mode file open mode(s) "or'd" together
*/
- void open( const std::string& name,
+ void open( const SGPath& name,
ios_openmode io_mode = ios_out|ios_binary );
/**