Skip to content

Commit

Permalink
Fix error output when creating directories (#561)
Browse files Browse the repository at this point in the history
Signed-off-by: Michael Carroll <mjcarroll@intrinsic.ai>
  • Loading branch information
mjcarroll authored Dec 4, 2023
1 parent 5b8f27f commit e899db5
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions src/Filesystem.cc
Original file line number Diff line number Diff line change
Expand Up @@ -466,11 +466,16 @@ bool common::copyDirectory(const std::string &_existingDirname,
/////////////////////////////////////////////////
bool common::createDirectories(const std::string &_path)
{
return createDirectories(_path, ignerr);
std::ostringstream ss;
auto ret = createDirectories(_path, ss);
if (!ret)
ignerr << ss.str();
return ret;
}

/////////////////////////////////////////////////
bool common::createDirectories(const std::string &_path, std::ostream &_errorOut)
bool common::createDirectories(
const std::string &_path, std::ostream &_errorOut)
{
size_t index = 0;
while (index < _path.size())
Expand Down

0 comments on commit e899db5

Please sign in to comment.