Browse Source

* Apply path in Mantis report 8103 to fix ansi2wide issue

git-svn-id: trunk@5916 -
daniel 18 years ago
parent
commit
a6a0745436
1 changed files with 2 additions and 1 deletions
  1. 2 1
      rtl/unix/cwstring.pp

+ 2 - 1
rtl/unix/cwstring.pp

@@ -219,11 +219,12 @@ procedure Ansi2WideMove(source:pchar;var dest:widestring;len:SizeInt);
             begin
               { skip and set to '?' }
               inc(srcpos);
+              dec(len);
               pwidechar(destpos)^:='?';
               inc(destpos,2);
               dec(outleft,2);
               { reset }
-              iconv(iconv_wide2ansi,@mynil,@my0,@mynil,@my0);
+              iconv(iconv_ansi2wide,@mynil,@my0,@mynil,@my0);
             end;
           ESysE2BIG:
             begin