Skip to content

Commit

Permalink
[image_view] Show full path when failed to save image
Browse files Browse the repository at this point in the history
  • Loading branch information
wkentaro committed Dec 3, 2015
1 parent 7ea1105 commit a671f94
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions image_view/src/nodes/image_view.cpp
Expand Up @@ -39,6 +39,7 @@

#include <boost/format.hpp>
#include <boost/thread.hpp>
#include <boost/filesystem.hpp>

int g_count;
cv::Mat g_last_image;
Expand Down Expand Up @@ -90,8 +91,8 @@ static void mouseCb(int event, int x, int y, int flags, void* param)
ROS_INFO("Saved image %s", filename.c_str());
g_count++;
} else {
/// @todo Show full path, ask if user has permission to write there
ROS_ERROR("Failed to save image.");
boost::filesystem::path full_path = boost::filesystem::complete(filename);
ROS_ERROR_STREAM("Failed to save image. Have permission to write there?: " << full_path);
}
}

Expand Down

0 comments on commit a671f94

Please sign in to comment.