Skip to content

Commit

Permalink
Fix compile error with std::filesystem::canonical()
Browse files Browse the repository at this point in the history
  • Loading branch information
jslee02 committed Jan 14, 2022
1 parent 49b7b0e commit 68c8928
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
5 changes: 4 additions & 1 deletion dart/common/Filesystem.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,8 @@
* POSSIBILITY OF SUCH DAMAGE.
*/

#pragma once
#ifndef DART_COMMON_FILESYSTEM_HPP_
#define DART_COMMON_FILESYSTEM_HPP_

#include "dart/common/Platform.hpp"

Expand Down Expand Up @@ -107,3 +108,5 @@ using error_code = ::std::error_code;
#endif

#endif // #ifndef DART_INCLUDE_STD_FILESYSTEM_EXPERIMENTAL

#endif // #ifndef DART_COMMON_FILESYSTEM_HPP_
2 changes: 1 addition & 1 deletion dart/gui/osg/render/MeshShapeNode.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -315,7 +315,7 @@ void MeshShapeNode::extractData(bool firstTime)
const common::filesystem::path relativeImagePath = imagePath.C_Str();
const common::filesystem::path absoluteImagePath
= common::filesystem::canonical(
relativeImagePath, meshPath.parent_path(), ec);
meshPath.parent_path() / relativeImagePath, ec);

if (ec)
{
Expand Down

0 comments on commit 68c8928

Please sign in to comment.