diff --git a/src/GTools.cpp b/src/GTools.cpp index c25d300..d7e5092 100644 --- a/src/GTools.cpp +++ b/src/GTools.cpp @@ -23,6 +23,10 @@ ***************************************************************************/ std::string strip_whitespace(const std::string arg) { + // Return empty string if argument is empty + if (arg.empty()) + return arg; + // Get start and stop std::string::size_type start = arg.find_first_not_of(' '); std::string::size_type stop = arg.find_last_not_of(' ');