Browse Source

* Merging revisions 43138 from trunk:
------------------------------------------------------------------------
r43138 | michael | 2019-10-06 10:04:10 +0200 (Sun, 06 Oct 2019) | 1 line

* Fix bug ID #36136, wrong reference count caused by missing const in param
------------------------------------------------------------------------

git-svn-id: branches/fixes_3_2@43262 -

michael 5 years ago
parent
commit
db1eb537c9
2 changed files with 3 additions and 3 deletions
  1. 2 2
      rtl/objpas/classes/classesh.inc
  2. 1 1
      rtl/objpas/classes/intf.inc

+ 2 - 2
rtl/objpas/classes/classesh.inc

@@ -2006,7 +2006,7 @@ type
     procedure Delete(index : Integer);
     procedure Exchange(index1,index2 : Integer);
     function First : IUnknown;
-    function IndexOf(item : IUnknown) : Integer;
+    function IndexOf(const item : IUnknown) : Integer;
     function Add(item : IUnknown) : Integer;
     procedure Insert(i : Integer;item : IUnknown);
     function Last : IUnknown;
@@ -2050,7 +2050,7 @@ type
     procedure Exchange(index1,index2 : Integer);
     function First : IUnknown;
     function GetEnumerator: TInterfaceListEnumerator;
-    function IndexOf(item : IUnknown) : Integer;
+    function IndexOf(const item : IUnknown) : Integer;
     function Add(item : IUnknown) : Integer;
     procedure Insert(i : Integer;item : IUnknown);
     function Last : IUnknown;

+ 1 - 1
rtl/objpas/classes/intf.inc

@@ -171,7 +171,7 @@
       end;
 
 
-    function TInterfaceList.IndexOf(item : IUnknown) : Integer;
+    function TInterfaceList.IndexOf(const item : IUnknown) : Integer;
       begin
         FList.Locklist;
         try