When a strong pointer is set to null the packaged build of the game will immediately close. No crash logs were were made and no Saved folder was made (<Project Name>/Saved/Logs).
An example project (built in 4.21) can be found here: [Link Removed].

Found in 4.22.3 CL#7053642
Reproduced in 4.21.2 CL#4753647, 4.23 Preview 4 Cl#7647024

Steps to Reproduce

1. Create a new C++ project.
2. Create two C++ classes derived from UObject (UMyStaticObject and UMyObjectWithStatics).
3. Declare a new variable inside UMyStaticObjectWithStatics "static TStrongObjectPrt<UMyStaticObject> examplePointer".
4. Initialize examplePointer in the cpp "TStrongObjectPtr<UMyStaticObject>UMyObjectWithStatics::examplePointer(nullptr)".
5. Compile.
6. Package the project for windows.
7. Run the packaged project.

Result: The packaged project closes out immediately.
Expected: The packaged project runs like normal.

Have Comments or More Details?

There's no existing public thread on this issue, so head over to Questions & Answers just mention UE-78309 in the post.

Login to Vote

ComponentUE - Foundation - Core
Affects Versions4.
Target Fix4.25
Fix Commit10469872
Main Commit11224363
CreatedAug 2, 2019
ResolvedNov 27, 2019
UpdatedAug 10, 2021