Boost logo

Boost :

From: Rory O'Connor (rsoconnor_at_[hidden])
Date: 2008-01-21 04:46:57


In the file \boost\libs\iostreams\src\mapped_file.cpp on line 126 there is a
simple member function called mapped_file_source::is_open().

It was assuming that an invalid handle was 0 but that is not true for a
Windows bulid.

I changed the function to the following:

bool mapped_file_source::is_open() const

{

#ifdef BOOST_IOSTREAMS_WINDOWS

return !!pimpl_ && pimpl_->handle_ != INVALID_HANDLE_VALUE;

#else

return !!pimpl_ && pimpl_->handle_ != 0;

#endif

}

This was from the latest revision of svn.

Regards


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk