Skip to content

Commit

Permalink
Remove remaining debug printings in vpIoTools
Browse files Browse the repository at this point in the history
  • Loading branch information
fspindle committed Mar 22, 2024
1 parent 215499d commit 0e8deda
Showing 1 changed file with 0 additions and 5 deletions.
5 changes: 0 additions & 5 deletions modules/core/src/tools/file/vpIoTools.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -832,20 +832,15 @@ bool vpIoTools::checkDirectory(const std::string &dirname)
std::string _dirname = path(dirname);

if (VP_STAT(_dirname.c_str(), &stbuf) != 0) {
std::cout << "DEBUG 1 _dirname: " << _dirname << " is not a dir" << std::endl;
// Test adding the separator if not already present
if (_dirname.at(_dirname.size() - 1) != separator) {
std::cout << "DEBUG 2 test if _dirname + separator: " << _dirname + separator << " is a dir ?" << std::endl;
if (VP_STAT((_dirname + separator).c_str(), &stbuf) != 0) {
std::cout << "DEBUG 2 _dirname + separator: " << _dirname + separator << " is not a dir" << std::endl;
return false;
}
}
// Test removing the separator if already present
if (_dirname.at(_dirname.size() - 1) == separator) {
std::cout << "DEBUG 2 test if _dirname - separator: " << _dirname.substr(0, _dirname.size() - 1) << " is a dir ?" << std::endl;
if (VP_STAT((_dirname.substr(0, _dirname.size() - 1)).c_str(), &stbuf) != 0) {
std::cout << "DEBUG 3 _dirname - separator: " << _dirname.substr(0, _dirname.size() - 1) << " is not a dir" << std::endl;
return false;
}
}
Expand Down

0 comments on commit 0e8deda

Please sign in to comment.