mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-09-12 14:52:25 +02:00
* symbols are cleared now after unloading the library (ClearLibrarySymbols)
git-svn-id: trunk@13979 -
This commit is contained in:
parent
47debd9850
commit
3e16584155
@ -101,7 +101,7 @@ procedure RaiseLibraryException(var Handler: TLibHandler);
|
|||||||
|
|
||||||
function LoadLibrarySymbols(const Lib: TLibHandle; const Symbols: PLibSymbol; const Count: Integer;
|
function LoadLibrarySymbols(const Lib: TLibHandle; const Symbols: PLibSymbol; const Count: Integer;
|
||||||
const ErrorSym: PPLibSymbol = nil): Boolean;
|
const ErrorSym: PPLibSymbol = nil): Boolean;
|
||||||
procedure ClearLibrarySymbols(const Lib: TLibHandle; const Symbols: PLibSymbol; const Count: Integer);
|
procedure ClearLibrarySymbols(const Symbols: PLibSymbol; const Count: Integer);
|
||||||
|
|
||||||
|
|
||||||
// these are for easier crossplatform construction of dll names in dynloading libs.
|
// these are for easier crossplatform construction of dll names in dynloading libs.
|
||||||
@ -266,6 +266,7 @@ begin
|
|||||||
begin
|
begin
|
||||||
if Assigned(Handler.Unloading) then
|
if Assigned(Handler.Unloading) then
|
||||||
Handler.Unloading(User, @Handler);
|
Handler.Unloading(User, @Handler);
|
||||||
|
ClearLibrarySymbols(Handler.Symbols, Handler.SymCount);
|
||||||
UnloadLibrary(Handler.Handle);
|
UnloadLibrary(Handler.Handle);
|
||||||
Handler.Handle := NilHandle;
|
Handler.Handle := NilHandle;
|
||||||
Handler.Filename := '';
|
Handler.Filename := '';
|
||||||
@ -311,7 +312,7 @@ begin
|
|||||||
Result := True;
|
Result := True;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure ClearLibrarySymbols(const Lib: TLibHandle; const Symbols: PLibSymbol; const Count: Integer);
|
procedure ClearLibrarySymbols(const Symbols: PLibSymbol; const Count: Integer);
|
||||||
var
|
var
|
||||||
P,L: PLibSymbol;
|
P,L: PLibSymbol;
|
||||||
begin
|
begin
|
||||||
|
Loading…
Reference in New Issue
Block a user