Fix potential NULL dereference
This commit is contained in:
parent
6d41bb9c55
commit
c64c98267c
@ -1542,11 +1542,10 @@ int ShLinkExt(
|
|||||||
TShHandleBase* base = reinterpret_cast<TShHandleBase*>(linkHandle);
|
TShHandleBase* base = reinterpret_cast<TShHandleBase*>(linkHandle);
|
||||||
TLinker* linker = static_cast<TLinker*>(base->getAsLinker());
|
TLinker* linker = static_cast<TLinker*>(base->getAsLinker());
|
||||||
|
|
||||||
SetThreadPoolAllocator(linker->getPool());
|
|
||||||
|
|
||||||
if (linker == nullptr)
|
if (linker == nullptr)
|
||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
|
SetThreadPoolAllocator(linker->getPool());
|
||||||
linker->infoSink.info.erase();
|
linker->infoSink.info.erase();
|
||||||
|
|
||||||
for (int i = 0; i < numHandles; ++i) {
|
for (int i = 0; i < numHandles; ++i) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user