浏览代码

* avoid conversion to larger type in Align

git-svn-id: trunk@34940 -
florian 8 年之前
父节点
当前提交
86f0b59095
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      rtl/inc/generic.inc

+ 1 - 1
rtl/inc/generic.inc

@@ -2044,7 +2044,7 @@ function align(addr : PtrUInt;alignment : PtrUInt) : PtrUInt;{$ifdef SYSTEMINLIN
   var
     tmp: PtrUInt;
   begin
-    tmp:=addr+(alignment-1);
+    tmp:=addr+PtrUInt(alignment-1);
     result:=tmp-(tmp mod alignment)
   end;