[Boost-bugs] [Boost C++ Libraries] #1232: mapped_file_source::is_open() is broken under windows

Subject: [Boost-bugs] [Boost C++ Libraries] #1232: mapped_file_source::is_open() is broken under windows
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2007-09-04 21:59:52


#1232: mapped_file_source::is_open() is broken under windows
-------------------------------------+--------------------------------------
 Reporter: royalstream_at_[hidden] | Owner: dgregor
     Type: Bugs | Status: new
Milestone: To Be Determined | Component: iostreams
  Version: Boost 1.34.1 | Severity: Problem
 Keywords: |
-------------------------------------+--------------------------------------
 Under windows, '''mapped_file_impl::handle_''' gets set to
 '''INVALID_HANDLE_VALUE''' when the file gets closed or on error.
 But '''mapped_file_source::is_open()''' incorrectly assumes that if the
 handle is invalid it will have a value of zero and it doesn't consider
 '''INVALID_HANDLE_VALUE''' a possibility.
 Obviously, adding '''INVALID_HANDLE_VALUE''' to
 '''mapped_file_source::is_open()''' would be poor design. A better way
 would be to explose a '''mapped_file_impl::is_valid()''' method that works
 as it should depending on the platform and have
 '''mapped_file_source::is_open()''' call it.

 Regards,

 Steven Burns

--
Ticket URL: <http://svn.boost.org/trac/boost/ticket/1232>
Boost C++ Libraries <http://www.boost.org/>
Boost provides free peer-reviewed portable C++ source libraries.


This archive was generated by hypermail 2.1.7 : 2017-02-16 18:49:56 UTC