Remove redundant function
authorThomas Jarosch <thomas.jarosch@intra2net.com>
Mon, 11 Oct 2010 08:40:46 +0000 (10:40 +0200)
committerThomas Jarosch <thomas.jarosch@intra2net.com>
Mon, 11 Oct 2010 08:40:46 +0000 (10:40 +0200)
src/util.cpp
src/util.hpp

index 3d5dd39..fe11814 100644 (file)
@@ -101,24 +101,9 @@ std::string compute_md5_digest(std::string data)
 
 /**
  * Get the status code from the given data.
- * @param data The data containing the status code at front, limited by " ".
- * @return The parsed status code.
- */
-std::string parse_status_code(std::string data)
-{
-    std::list<std::string> tokens;
-    boost::algorithm::split(tokens,data,boost::is_any_of(" "));
-    if ( tokens.empty() )
-        return "";
-    return tokens.front();
-}
-
-
-/**
- * Get the status code from the given data.
- * @param data The data containing the status code at front, limited by " ".
+ * @param data The data containing the status code at front, limited by delimiter.
  * @param delimiter The delimiter to use.
- * @return The parsed status code.
+ * @return The parsed status code
  */
 std::string parse_status_code(std::string data, std::string delimiter)
 {
index 5593ef2..3f886ea 100644 (file)
@@ -18,8 +18,7 @@
 namespace Util
 {
     std::string compute_md5_digest(std::string data);
-    std::string parse_status_code(std::string data);
-    std::string parse_status_code(std::string data, std::string delimiter);
+    std::string parse_status_code(std::string data, std::string delimiter=" ");
 }
 
 #endif