Enhancement

- Added Path::is_absolute, and corresponding unit tests.
- Replaced expandPath and isAbsolutePath call in Config.cpp.
This commit is contained in:
Paul Beckingham 2010-01-12 01:30:59 -05:00
parent c02cfd594c
commit e1f3f2355a
4 changed files with 20 additions and 3 deletions

View file

@ -100,8 +100,8 @@ bool Config::load (const std::string& file, int nest /* = 1 */)
std::string::size_type include = line.find ("include"); // no i18n.
if (include != std::string::npos)
{
Path included (expandPath (trim (line.substr (include + 7), " \t")));
if (isAbsolutePath (included.data))
Path included (trim (line.substr (include + 7), " \t"));
if (included.is_absolute ())
{
if (included.readable ())
this->load (included.data, nest + 1);