Browse Source

amunits: actually, the DoMethodA() fix by Marcus added in r32699 is correct, and the old version was wrong. so remove remark about TODO, and leftovers of the old code.

git-svn-id: trunk@32704 -
Károly Balogh 9 years ago
parent
commit
21352ca934
1 changed files with 1 additions and 6 deletions
  1. 1 6
      packages/amunits/src/coreunits/amigalib.pas

+ 1 - 6
packages/amunits/src/coreunits/amigalib.pas

@@ -362,14 +362,9 @@ begin
 end;
 
 function DoMethodA(obj : pObject_; msg : APTR): ulong;
-//var
-//    o : p_Object;
 begin
     if assigned(obj) then begin
-       //o := p_Object(obj);
-       DoMethodA := CallHookPkt(PHook(OCLASS(obj)), obj, msg);
-       //TODO: Investigate why this call crashes and the other work, both do the same in principle
-       //DoMethodA := CallHookPkt(@o^.o_Class^.cl_Dispatcher, obj,msg);
+       DoMethodA := CallHookPkt(@THook(OCLASS(obj)^.cl_Dispatcher), obj, msg);
     end else DoMethodA := 0;
 end;