File tree Expand file tree Collapse file tree 1 file changed +2
-4
lines changed
python4lazarus/Sources/Core Expand file tree Collapse file tree 1 file changed +2
-4
lines changed Original file line number Diff line number Diff line change @@ -6063,8 +6063,6 @@ function TPythonEngine.PyObjectAsVariant( obj : PPyObject ) : Variant;
60636063end ;
60646064
60656065function TPythonEngine.VarRecAsPyObject ( v : TVarRec ) : PPyObject;
6066- var
6067- buff : array [0 ..256 ] of AnsiChar;
60686066begin
60696067 case v.VType of
60706068 vtInteger: Result := PyInt_FromLong( v.VInteger );
@@ -6074,7 +6072,7 @@ function TPythonEngine.VarRecAsPyObject( v : TVarRec ) : PPyObject;
60746072 vtString:
60756073 begin
60766074 if Assigned(v.VString) then
6077- Result := PyString_FromString( StrPCopy( buff, v.VString^) )
6075+ Result := PyString_FromString(PAnsiChar(AnsiString( v.VString^)) )
60786076 else
60796077 Result := PyString_FromString( ' ' );
60806078 end ;
@@ -6200,7 +6198,7 @@ function TPythonEngine.ArrayToPyDict( items : array of const) : PPyObject;
62006198 vtAnsiString:
62016199 begin
62026200 if Assigned(v.VAnsiString) then
6203- Result := StrPas(PAnsiChar( Ansistring(v.VAnsiString)) )
6201+ Result := Ansistring(v.VAnsiString)
62046202 else
62056203 Result := ' ' ;
62066204 end ;
You can’t perform that action at this time.
0 commit comments