Explorar o código

Fixed bug in split when final word has length 1 (bug ID 29798)

git-svn-id: trunk@33209 -
michael %!s(int64=9) %!d(string=hai) anos
pai
achega
839a0445a4
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      rtl/objpas/sysutils/syshelp.inc

+ 1 - 1
rtl/objpas/sysutils/syshelp.inc

@@ -1193,7 +1193,7 @@ begin
     LastSep:=Sep+1;
     Sep:=NextSep(LastSep);
     end;
-  if (LastSep<Length-1) and ((ACount=0) or (Len<ACount)) then
+  if (LastSep<Length) and ((ACount=0) or (Len<ACount)) then
     begin
     T:=SubString(LastSep);
 //    Writeln('Examining >',T,'< at pos,',LastSep,' till pos ',Sep);