Boost logo

Boost Users :

Subject: [Boost-users] ENH RQST: chdir in boost::filesystem
From: Andrew Marlow (marlow.andrew_at_[hidden])
Date: 2009-11-03 14:05:33


I have recently moved back to C++ from a 2 year spell with Java. The C++
code I am working on is for Windoze with Visual Studio 8. We are using boost
1.34.1. The prog I am working on has to do a few filesystem things so I have
started to use boost::filesystem. However, there does not seem to be a way
to change the current working directory using boost::filesystem. So I am
forced to use chdir, which is _chdir on Windoze. On Unix the header for the
prototype is in unistd.h, on Windoze it is in direct.h. So its back to good
old ifdefs. Suddenly, java looks more attractive. Ifdefs are just so
nostalgic....

Is there any chance this can be added to boost please?

I realise that there may be more to it than just wrapping the chdir/_chdir
call. There is the whole issue of return values versus exceptions, errno etc
etc. I do not know what the current thinking is about these things in boost.
Perhaps someone can enlighten me?

-- 
Regards,
Andrew M.
http://www.andrewpetermarlow.co.uk


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