mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-04-21 18:29:27 +02:00
* correction for copy&paste error in previous commit
git-svn-id: trunk@21908 -
This commit is contained in:
parent
4dccf2d321
commit
2bcfe75ea8
@ -73,34 +73,6 @@ begin
|
||||
Result := DynLibErrNo = 0;
|
||||
end;
|
||||
|
||||
function GetDynLibsErrorStr: string;
|
||||
const
|
||||
SysMsgFile: array [0..10] of char = 'OSO001.MSG'#0;
|
||||
var
|
||||
VarArr: array [1..9] of PChar;
|
||||
OutBuf: array [0..999] of char;
|
||||
RetMsgSize: cardinal;
|
||||
RC: cardinal;
|
||||
begin
|
||||
if DynLibErrNo = 0 then
|
||||
GetDynLibsErrorStr := ''
|
||||
else
|
||||
begin
|
||||
VarArr [1] := @DynLibErrPath [0];
|
||||
RC := DosGetMessage (@VarArr, 1, @OutBuf [0], SizeOf (OutBuf),
|
||||
DynLibErrNo, @SysMsgFile [0], RetMsgSize);
|
||||
if RC = 0 then
|
||||
Result := StrPas (@OutBuf [0])
|
||||
else
|
||||
begin
|
||||
WriteStr (Result, DynLibErrNo);
|
||||
Result := 'Error ' + Result;
|
||||
end;
|
||||
if DynLibErrPath [0] <> #0 then
|
||||
Result := StrPas (@DynLibErrPath [0]) + ' - ' + Result;
|
||||
end;
|
||||
end;
|
||||
|
||||
function GetDynLibsError: longint;
|
||||
begin
|
||||
GetDynLibsError := DynLibErrNo;
|
||||
|
Loading…
Reference in New Issue
Block a user