diff options
Diffstat (limited to 'glcdgraphics')
-rw-r--r-- | glcdgraphics/common.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/glcdgraphics/common.c b/glcdgraphics/common.c index 1c78e23..0fd78b8 100644 --- a/glcdgraphics/common.c +++ b/glcdgraphics/common.c @@ -6,7 +6,8 @@ * This file is released under the GNU General Public License. Refer * to the COPYING file distributed with this package. * - * (c) 2004 Andreas Regel <andreas.regel AT powarman.de> + * (c) 2004 Andreas Regel <andreas.regel AT powarman.de> + * (c) 2010-2012 Wolfgang Astleitner <mrwastl AT users sourceforge net> */ #include <ctype.h> @@ -49,7 +50,7 @@ std::string trim(const std::string & s) start++; } end = s.length() - 1; - while (end >= 0) + while (end > start) { if (!isspace(s[end])) break; |