]> granicus.if.org Git - php/commitdiff
Fixing bug 8061. Position counter starts a 0 but was compared with length.
authorFrank M. Kromann <fmk@php.net>
Fri, 1 Dec 2000 01:55:31 +0000 (01:55 +0000)
committerFrank M. Kromann <fmk@php.net>
Fri, 1 Dec 2000 01:55:31 +0000 (01:55 +0000)
oops. the fix should be made twice.

ext/standard/string.c

index 65a5a843ba6e47fabb7b08cf333de84707d69ad4..089f64287693e39758fe9489c82fd9c4fd7fb822 100644 (file)
@@ -331,7 +331,7 @@ PHP_FUNCTION(wordwrap)
                                }
                                l ++;
                        }
-                       if (l > linelength) {
+                       if (l >= linelength) {
                                pgr = l;
                                l = linelength;