From 9b0557c2c31dbc95b040ac79b17804f6da6c5dcb Mon Sep 17 00:00:00 2001 From: Dieter Hametner Date: Sun, 7 Jan 2007 23:25:01 +0000 Subject: added StringRepeat function to tools --- tools.cpp | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'tools.cpp') diff --git a/tools.cpp b/tools.cpp index 515418a..de0b43c 100644 --- a/tools.cpp +++ b/tools.cpp @@ -62,4 +62,13 @@ int StringToInt( std::string const& string, int base ) return 0; } +string StringRepeat(int times, const string& input) +{ + string result; + for (int i = 0; i < times; i++) { + result += input; + } + return result; +} + } // namespace vdrlive -- cgit v1.2.3