Description

The Editor will crash in PIE when an Actor calls a method in a UObject that modifies some FString members in the UObject. In the Attached project, the UObject class contains two FString members and two methods. There is also an Actor class that contains an instance of the UObject. In the Actor's constructor, the first method is called which sets the initial values for the UObject's FString members. On BeginPlay, the Actor calls the second UObject method that attempts to modify the UObject's FString members. The crash occurs when the method attempts to set a new value for one of the FStrings.

Steps to Reproduce
  1. Download the attached project.
    • Project created in Main at CL 4858162.
  2. Associate the project with your version of Main.
  3. Build the project in Visual Studio.
  4. Open the project in the Editor.
  5. Start PIE.

RESULT:
The Editor will crash when attempting to modify an FString member in a UObject.

EXPECTED:
The Editor starts PIE and the log displays some log messages from the UObject as it modifies its FString members.

Callstack
Unhandled exception: EXCEPTION_ACCESS_VIOLATION reading address 0x00000038

UE4Editor_Core!FString::operator=() [d:\main-builds\stream\engine\source\runtime\core\public\containers\unrealstring.h:1865]
UE4Editor_TESTFString2!UMyObject::SecondMethod() [d:\unreal projects\current issues\testfstring2\source\testfstring2\myobject.cpp:21]
UE4Editor_Engine!AActor::DispatchBeginPlay() [d:\main-builds\stream\engine\source\runtime\engine\private\actor.cpp:3351]
UE4Editor_Engine!AWorldSettings::NotifyBeginPlay() [d:\main-builds\stream\engine\source\runtime\engine\private\worldsettings.cpp:251]
UE4Editor_Engine!AGameStateBase::HandleBeginPlay() [d:\main-builds\stream\engine\source\runtime\engine\private\gamestatebase.cpp:177]
UE4Editor_Engine!UWorld::BeginPlay() [d:\main-builds\stream\engine\source\runtime\engine\private\world.cpp:3934]
UE4Editor_Engine!UGameInstance::StartPlayInEditorGameInstance() [d:\main-builds\stream\engine\source\runtime\engine\private\gameinstance.cpp:413]
UE4Editor_UnrealEd!UEditorEngine::CreatePIEGameInstance() [d:\main-builds\stream\engine\source\editor\unrealed\private\playlevel.cpp:3338]
UE4Editor_UnrealEd!UEditorEngine::PlayInEditor() [d:\main-builds\stream\engine\source\editor\unrealed\private\playlevel.cpp:2465]
UE4Editor_UnrealEd!UEditorEngine::StartQueuedPlayMapRequest() [d:\main-builds\stream\engine\source\editor\unrealed\private\playlevel.cpp:1279]
UE4Editor_UnrealEd!UEditorEngine::Tick() [d:\main-builds\stream\engine\source\editor\unrealed\private\editorengine.cpp:1532]
UE4Editor_UnrealEd!UUnrealEdEngine::Tick() [d:\main-builds\stream\engine\source\editor\unrealed\private\unrealedengine.cpp:403]
UE4Editor!FEngineLoop::Tick() [d:\main-builds\stream\engine\source\runtime\launch\private\launchengineloop.cpp:3954]
UE4Editor!GuardedMain() [d:\main-builds\stream\engine\source\runtime\launch\private\launch.cpp:168]
UE4Editor!GuardedMainWrapper() [d:\main-builds\stream\engine\source\runtime\launch\private\windows\launchwindows.cpp:145]
UE4Editor!WinMain() [d:\main-builds\stream\engine\source\runtime\launch\private\windows\launchwindows.cpp:275]
UE4Editor!__scrt_common_main_seh() [d:\agent\_work\3\s\src\vctools\crt\vcstartup\src\startup\exe_common.inl:288]
kernel32
ntdll

Have Comments or More Details?

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

0
Login to Vote

Non-Issue
ComponentUE - Foundation - Core
Affects Versions4.19.24.224.20.3
Target Fix4.22
CreatedJan 31, 2019
ResolvedFeb 8, 2019
UpdatedFeb 15, 2019