Procházet zdrojové kódy

kernel: add missing TLR clear

Liam před 2 roky
rodič
revize
bb195c2c2b
1 změnil soubory, kde provedl 1 přidání a 0 odebrání
  1. 1 0
      src/core/hle/kernel/k_thread.cpp

+ 1 - 0
src/core/hle/kernel/k_thread.cpp

@@ -215,6 +215,7 @@ Result KThread::Initialize(KThreadFunction func, uintptr_t arg, KProcessAddress
         // Setup the TLS, if needed.
         if (type == ThreadType::User) {
             R_TRY(owner->CreateThreadLocalRegion(std::addressof(m_tls_address)));
+            owner->GetMemory().ZeroBlock(m_tls_address, Svc::ThreadLocalRegionSize);
         }
 
         m_parent = owner;