Skip to content

Commit 250c0c2

Browse files
authored
Replace boost::filesystem::extension() (ros-visualization#1844)
boost::filesystem::extension was deprecated in Boost 1.77 and removed in 1.85 https://www.boost.org/doc/libs/1_87_0_beta1/libs/filesystem/doc/release_history.html The alternative, calling the member function extension() on boost::fs::path works on Noetic.
1 parent fdcf656 commit 250c0c2

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/rviz/mesh_loader.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -408,7 +408,7 @@ void loadTexture(const std::string& resource_path)
408408
{
409409
Ogre::DataStreamPtr stream(new Ogre::MemoryDataStream(res.data.get(), res.size));
410410
Ogre::Image image;
411-
std::string extension = fs::extension(fs::path(resource_path));
411+
std::string extension = fs::path(resource_path).extension().string();
412412

413413
if (extension[0] == '.')
414414
{

src/rviz/robot/robot_link.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -518,7 +518,7 @@ Ogre::MaterialPtr RobotLink::getMaterialForLink(const urdf::LinkConstSharedPtr&
518518
{
519519
Ogre::DataStreamPtr stream(new Ogre::MemoryDataStream(res.data.get(), res.size));
520520
Ogre::Image image;
521-
std::string extension = fs::extension(fs::path(filename));
521+
std::string extension = fs::path(filename).extension().string();
522522

523523
if (extension[0] == '.')
524524
{

0 commit comments

Comments
 (0)