Subject: Re: [Boost-bugs] [Boost C++ Libraries] #2260: Missing slash when iterating windows root path
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2009-01-12 00:33:21
#2260: Missing slash when iterating windows root path
------------------------------------------------------+---------------------
Reporter: Lin Yi-Li <record.nctu.cis91_at_[hidden]> | Owner: bemandawes
Type: Bugs | Status: closed
Milestone: To Be Determined | Component: filesystem
Version: Boost 1.36.0 | Severity: Problem
Resolution: invalid | Keywords: directory_iterator seperator
------------------------------------------------------+---------------------
Changes (by bemandawes):
* status: new => closed
* resolution: => invalid
Comment:
"C:filename" is perfectly valid. Windows interprets the directory as being
the current working directory on the C drive. This is demonstrated from
the command line by:
>dir
Volume in drive C has no label.
Volume Serial Number is D4A2-EC0D
Directory of C:\boost\trunk\libs\filesystem\test\msvc\ticket_2260_test
01/11/2009 07:05 PM <DIR> .
01/11/2009 07:05 PM <DIR> ..
01/11/2009 07:12 PM <DIR> Debug
01/11/2009 07:05 PM 4,070 ticket_2260_test.vcproj
01/11/2009 07:15 PM 1,409
ticket_2260_test.vcproj.BGD.Administrator.user
2 File(s) 5,479 bytes
3 Dir(s) 210,340,593,664 bytes free
>dir c:
Volume in drive C has no label.
Volume Serial Number is D4A2-EC0D
Directory of C:\boost\trunk\libs\filesystem\test\msvc\ticket_2260_test
01/11/2009 07:05 PM <DIR> .
01/11/2009 07:05 PM <DIR> ..
01/11/2009 07:12 PM <DIR> Debug
01/11/2009 07:05 PM 4,070 ticket_2260_test.vcproj
01/11/2009 07:15 PM 1,409
ticket_2260_test.vcproj.BGD.Administrator.user
2 File(s) 5,479 bytes
3 Dir(s) 210,340,626,432 bytes free
Note the way that "dir c:" works.
If you want C:\ rather than the current C: directory, change line 10 to:
const char *drive_to_search = "C:\\";
--Beman
-- Ticket URL: <https://svn.boost.org/trac/boost/ticket/2260#comment:1> 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:59 UTC