FRunnableThread::Kill

Tells the thread to exit.

Windows
MacOS
Linux

References

Module

Core

Header

/Engine/Source/Runtime/Core/Public/HAL/RunnableThread.h

Include

#include "HAL/RunnableThread.h"

Syntax

bool Kill
(
    bool bShouldWait
)

Remarks

Tells the thread to exit. If the caller needs to know when the thread has exited, it should use the bShouldWait value. It's highly recommended not to kill the thread without waiting for it. Having a thread forcibly destroyed can cause leaks and deadlocks.

The kill method is calling Stop() on the runnable to kill the thread gracefully.

Returns

Always true

Parameters

Parameter

Description

bShouldWait

If true, the call will wait infinitely for the thread to exit.

Help shape the future of Unreal Engine documentation! Tell us how we're doing so we can serve you better.
Take our survey
Dismiss