* cache inoutres threadvar address

git-svn-id: trunk@8824 -
This commit is contained in:
peter 2007-10-16 19:12:29 +00:00
parent 4f862a23a7
commit cd35804502

View File

@ -607,20 +607,25 @@ end;
procedure fpc_iocheck;[public,alias:'FPC_IOCHECK']; compilerproc; procedure fpc_iocheck;[public,alias:'FPC_IOCHECK']; compilerproc;
var var
l : longint; l : longint;
HInoutRes : PWord;
begin begin
if InOutRes<>0 then HInOutRes:=@InoutRes;
if HInOutRes^<>0 then
begin begin
l:=InOutRes; l:=HInOutRes^;
InOutRes:=0; HInOutRes^:=0;
HandleErrorFrame(l,get_frame); HandleErrorFrame(l,get_frame);
end; end;
end; end;
Function IOResult:Word;{$ifdef SYSTEMINLINE}inline;{$endif} Function IOResult:Word;{$ifdef SYSTEMINLINE}inline;{$endif}
var
HInoutRes : PWord;
Begin Begin
IOResult:=InOutRes; HInoutRes:=@InoutRes;
InOutRes:=0; IOResult:=HInOutRes^;
HInOutRes^:=0;
End; End;