mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-08-12 07:46:00 +02:00
* Patch from Luca Olivetti to fix memleak in CORS support. Fixes issue #39886
This commit is contained in:
parent
b6a7504665
commit
bc100eda4d
@ -119,6 +119,7 @@ Type
|
|||||||
Property CORS : TCORSSupport Read FCORS Write SetCORS;
|
Property CORS : TCORSSupport Read FCORS Write SetCORS;
|
||||||
public
|
public
|
||||||
Constructor CreateNew(aOwner : TComponent; CreateMode: Integer); overload; override;
|
Constructor CreateNew(aOwner : TComponent; CreateMode: Integer); overload; override;
|
||||||
|
destructor Destroy;override;
|
||||||
Class Procedure RegisterModule(Const AModuleName : String = ''); overload;
|
Class Procedure RegisterModule(Const AModuleName : String = ''); overload;
|
||||||
Class Procedure RegisterModule(Const AModuleName : String; ASkipStreaming : Boolean); overload;
|
Class Procedure RegisterModule(Const AModuleName : String; ASkipStreaming : Boolean); overload;
|
||||||
Procedure HandleRequest(ARequest : TRequest; AResponse : TResponse); virtual; abstract;
|
Procedure HandleRequest(ARequest : TRequest; AResponse : TResponse); virtual; abstract;
|
||||||
@ -322,6 +323,12 @@ begin
|
|||||||
FCORS:=CreateCORSSupport;
|
FCORS:=CreateCORSSupport;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
destructor TCustomHTTPModule.Destroy;
|
||||||
|
begin
|
||||||
|
FCORS.Free;
|
||||||
|
inherited Destroy;
|
||||||
|
end;
|
||||||
|
|
||||||
Class Procedure TCustomHTTPModule.RegisterModule(Const AModuleName: String);
|
Class Procedure TCustomHTTPModule.RegisterModule(Const AModuleName: String);
|
||||||
begin
|
begin
|
||||||
RegisterModule(AModuleName,DefaultSkipStreaming);
|
RegisterModule(AModuleName,DefaultSkipStreaming);
|
||||||
|
Loading…
Reference in New Issue
Block a user