1
0
mirror of https://github.com/salvadordf/CEF4Delphi.git synced 2025-11-23 21:34:53 +02:00

Update to CEF 3.3325.1749.ga42963a

This commit is contained in:
Salvador Díaz Fau
2018-03-17 11:12:03 +01:00
parent fd7ff7f70a
commit 15581a9c06
5 changed files with 57 additions and 24 deletions

View File

@@ -153,13 +153,17 @@ destructor TCefBaseRefCountedOwn.Destroy;
var
TempPointer : pointer;
begin
TempPointer := FData;
FData := nil;
Dec(PByte(TempPointer), SizeOf(Pointer));
FreeMem(TempPointer);
inherited Destroy;
try
if (FData <> nil) then
begin
TempPointer := FData;
Dec(PByte(TempPointer), SizeOf(Pointer));
FreeMem(TempPointer);
end;
finally
FData := nil;
inherited Destroy;
end;
end;
function TCefBaseRefCountedOwn.Wrap: Pointer;
@@ -180,15 +184,13 @@ end;
destructor TCefBaseRefCountedRef.Destroy;
begin
if (FData <> nil) then
begin
if assigned(PCefBaseRefCounted(FData)^.release) then
PCefBaseRefCounted(FData)^.release(PCefBaseRefCounted(FData));
FData := nil;
end;
inherited Destroy;
try
if (FData <> nil) and assigned(PCefBaseRefCounted(FData)^.release) then
PCefBaseRefCounted(FData)^.release(PCefBaseRefCounted(FData));
finally
FData := nil;
inherited Destroy;
end;
end;
class function TCefBaseRefCountedRef.UnWrap(data: Pointer): ICefBaseRefCounted;