mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-09-07 18:30:32 +02:00
* Clear request/response variables in case of an error
git-svn-id: trunk@25179 -
This commit is contained in:
parent
5459dc4401
commit
db0585f388
@ -219,10 +219,13 @@ procedure TFPHTTPServerHandler.HTTPHandleRequest(Sender: TObject;
|
||||
var AResponse: TFPHTTPConnectionResponse);
|
||||
begin
|
||||
// Exceptions are handled by (Do)HandleRequest. It also frees the response/request
|
||||
DoHandleRequest(ARequest,AResponse);
|
||||
ARequest:=Nil;
|
||||
AResponse:=Nil;
|
||||
If Terminated then
|
||||
try
|
||||
DoHandleRequest(ARequest,AResponse);
|
||||
finally
|
||||
ARequest:=Nil;
|
||||
AResponse:=Nil;
|
||||
end;
|
||||
If Terminated And Assigned(FServer) then
|
||||
FServer.Active:=False;
|
||||
if Assigned(OnIdle) then
|
||||
OnIdle(Self);
|
||||
|
Loading…
Reference in New Issue
Block a user