mirror of
https://github.com/neoStudiosLCE/neoLegacy.git
synced 2026-06-09 02:13:09 +00:00
fix: add null check for TLS compression pointer
This commit is contained in:
parent
fd21c3bc0e
commit
4191b654b2
|
|
@ -51,6 +51,9 @@ void Compression::ReleaseThreadStorage()
|
|||
Compression *Compression::getCompression()
|
||||
{
|
||||
const ThreadStorage *tls = static_cast<ThreadStorage *>(TlsGetValue(tlsIdx));
|
||||
if (!tls) {
|
||||
return nullptr;
|
||||
}
|
||||
return tls->compression;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue