소스 검색

* fixed fpc_tcon_shortint_array_from_string() in case the length of the array
to initialize was odd

git-svn-id: branches/jvmbackend@20210 -

Jonas Maebe 13 년 전
부모
커밋
8b4b081ed5
1개의 변경된 파일1개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 1
      rtl/java/jtcon.inc

+ 1 - 1
rtl/java/jtcon.inc

@@ -27,7 +27,7 @@ procedure fpc_tcon_shortint_array_from_string(const s: unicodestring; var arr: a
         arr[startindex+i*2+1]:=shortint(ord(c));
       end;
     if odd(len) then
-      arr[startindex+len-1]:=ord(s[len div 2]) shr 8;
+      arr[startindex+len-1]:=ord(s[len div 2 + 1]) shr 8;
   end;