File tree 2 files changed +0
-21
lines changed
2 files changed +0
-21
lines changed Original file line number Diff line number Diff line change @@ -1748,7 +1748,6 @@ TPythonEngine = class(TPythonInterface)
1748
1748
FRedirectIO: Boolean;
1749
1749
FOnAfterInit: TNotifyEvent;
1750
1750
FClients: TList;
1751
- FLock: TCriticalSection;
1752
1751
FExecModule: AnsiString;
1753
1752
FAutoFinalize: Boolean;
1754
1753
FProgramName: UnicodeString;
@@ -1801,8 +1800,6 @@ TPythonEngine = class(TPythonInterface)
1801
1800
destructor Destroy; override;
1802
1801
1803
1802
// Public methods
1804
- procedure Lock ;
1805
- procedure Unlock ;
1806
1803
procedure SetPythonHome (const PythonHome: UnicodeString);
1807
1804
procedure SetProgramName (const ProgramName: UnicodeString);
1808
1805
function IsType (ob: PPyObject; obt: PPyTypeObject): Boolean;
@@ -3936,7 +3933,6 @@ constructor TPythonEngine.Create(AOwner: TComponent);
3936
3933
i : Integer;
3937
3934
begin
3938
3935
inherited ;
3939
- FLock := TCriticalSection.Create;
3940
3936
FInitScript := TstringList.Create;
3941
3937
FClients := TList.Create;
3942
3938
FRedirectIO := True;
@@ -3968,7 +3964,6 @@ destructor TPythonEngine.Destroy;
3968
3964
FClients.Free;
3969
3965
FInitScript.Free;
3970
3966
FTraceback.Free;
3971
- FLock.Free;
3972
3967
{ $IFNDEF FPC}
3973
3968
inherited ;
3974
3969
{ $ENDIF}
@@ -4039,16 +4034,6 @@ procedure TPythonEngine.Finalize;
4039
4034
FPyDateTime_DateTimeTZType := nil ;
4040
4035
end ;
4041
4036
4042
- procedure TPythonEngine.Lock ;
4043
- begin
4044
- FLock.Enter;
4045
- end ;
4046
-
4047
- procedure TPythonEngine.Unlock ;
4048
- begin
4049
- FLock.Leave;
4050
- end ;
4051
-
4052
4037
procedure TPythonEngine.AfterLoad ;
4053
4038
begin
4054
4039
inherited ;
Original file line number Diff line number Diff line change @@ -282,9 +282,6 @@ constructor PyTRandomInteger.CreateWith(PythonType: TPythonType;
282
282
try
283
283
inherited ;
284
284
285
- // obtain lock
286
- Lock;
287
-
288
285
// create object
289
286
FRandomInteger := TRandomInteger.Create;
290
287
@@ -294,9 +291,6 @@ constructor PyTRandomInteger.CreateWith(PythonType: TPythonType;
294
291
// try to parse
295
292
if (PyArg_ParseTuple(args, ' |O:CreateWith' , @val1) <> 0 ) and Assigned(val1) then
296
293
FRandomInteger.Value := PythonToTRandomInteger(val1).Value ;
297
-
298
- // unlock
299
- Unlock;
300
294
except
301
295
on e: Exception do
302
296
PyErr_SetString(PyExc_Exception^, PAnsiChar(AnsiString(e.Message)));
You can’t perform that action at this time.
0 commit comments