Boost logo

Boost :

From: eg (egoots_at_[hidden])
Date: 2008-01-22 13:48:46


Rory O'Connor wrote:
> 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
>
> }
>

I think the preferred approach is to log a bug in the bug tracker
against the iostreams component at http://svn.boost.org/trac/boost/

Perhaps a little test case which demonstrates the error too.


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