Fixed bug with length calculation

Fixed build errors like below:
-- Using CATKIN_TEST_RESULTS_DIR:
~/ros_catkin_ws/build_isolated/rqt_image_view/test_results
-- Found gtest sources under '/usr/src/gtest': gtests will be built
-- catkin 0.5.84
CMake Error at
/opt/ros/hydro_custom/share/catkin/cmake/catkin_package.cmake:399
(string):
  string end index: 57 is out of range -1 - 56
Merge pull request #601 from cehberlin/indigo-devel

Fixed bug with length calculation