Boost logo

Boost Users :

Subject: Re: [Boost-users] boost::filesystem::current_path().string()
From: Scott McMurray (me22.ca+boost_at_[hidden])
Date: 2011-04-20 17:35:49


On Wed, Apr 20, 2011 at 13:35, buster buster <buster2007_at_[hidden]> wrote:
> i'm using "boost::filesystem::current_path().string()"
> from a dll
>

To quote the reference documentation:

    "The current path as returned by many operating systems is a
dangerous global variable. It may be changed unexpectedly by a
third-party or system library functions, or by another thread."

It also depends on how you open the executable, and all kinds of other
things. Be explicit about your paths, and have the program using your
DLL tell you what path it wants you to use.

~ Scott


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net