Welcome, Guest

Author Topic: GEngine->Browse() causes crash  (Read 282 times)

jvukovich

  • Posts: 29
    • View Profile
GEngine->Browse() causes crash
« on: December 04, 2016, 10:26:33 AM »
This code:
Code: [Select]
FString Error;
FURL URL(*FString("MAP_Verran"));
GEngine->Browse(*GetGameInstance()->GetWorldContext(), URL, Error);

Causes crash:
Code: [Select]
Unhandled Exception: EXCEPTION_ACCESS_VIOLATION reading address 0xffffffff

UE4Editor-Ascentroid.dll
UE4Editor-Ascentroid.dll
CoherentUIGT.dll
CoherentUIGT.dll
CoherentUIGT.dll
CoherentGTJS.dll
CoherentGTJS.dll
CoherentGTJS.dll
CoherentGTJS.dll
CoherentGTJS.dll
CoherentGTJS.dll
CoherentGTJS.dll
CoherentGTCore.dll
CoherentGTCore.dll
CoherentGTCore.dll
CoherentGTCore.dll
CoherentGTCore.dll
CoherentGTCore.dll
CoherentGTCore.dll
CoherentGTCore.dll
CoherentGTCore.dll
CoherentGTCore.dll
CoherentUIGT.dll
UE4Editor-CoherentUIGTPlugin.dll
UE4Editor-CoherentUIGTPlugin.dll
UE4Editor-Slate.dll!<lambda_c23ab8315e6b1cb056a6ce07a4352f32>::operator()() [c:\dev\ue4\4.12.5\engine\source\runtime\slate\private\framework\application\slateapplication.cpp:4630]
UE4Editor-Slate.dll!FEventRouter::Route<FReply,FEventRouter::FBubblePolicy,FPointerEvent,<lambda_c23ab8315e6b1cb056a6ce07a4352f32> >() [c:\dev\ue4\4.12.5\engine\source\runtime\slate\private\framework\application\slateapplication.cpp:215]
UE4Editor-Slate.dll!FSlateApplication::RoutePointerUpEvent() [c:\dev\ue4\4.12.5\engine\source\runtime\slate\private\framework\application\slateapplication.cpp:4621]
UE4Editor-Slate.dll!FSlateApplication::ProcessMouseButtonUpEvent() [c:\dev\ue4\4.12.5\engine\source\runtime\slate\private\framework\application\slateapplication.cpp:5041]
UE4Editor-Slate.dll!FSlateApplication::OnMouseUp() [c:\dev\ue4\4.12.5\engine\source\runtime\slate\private\framework\application\slateapplication.cpp:5021]
UE4Editor-Core.dll!FWindowsApplication::ProcessDeferredMessage() [c:\dev\ue4\4.12.5\engine\source\runtime\core\private\windows\windowsapplication.cpp:1510]
UE4Editor-Core.dll!FWindowsApplication::DeferMessage() [c:\dev\ue4\4.12.5\engine\source\runtime\core\private\windows\windowsapplication.cpp:1850]
UE4Editor-Core.dll!FWindowsApplication::ProcessMessage() [c:\dev\ue4\4.12.5\engine\source\runtime\core\private\windows\windowsapplication.cpp:745]
UE4Editor-Core.dll!FWindowsApplication::AppWndProc() [c:\dev\ue4\4.12.5\engine\source\runtime\core\private\windows\windowsapplication.cpp:667]
USER32.dll
USER32.dll
UE4Editor-Core.dll!FWindowsPlatformMisc::PumpMessages() [c:\dev\ue4\4.12.5\engine\source\runtime\core\private\windows\windowsplatformmisc.cpp:903]
UE4Editor.exe!FEngineLoop::Tick() [c:\dev\ue4\4.12.5\engine\source\runtime\launch\private\launchengineloop.cpp:2729]
UE4Editor.exe!GuardedMain() [c:\dev\ue4\4.12.5\engine\source\runtime\launch\private\launch.cpp:148]
UE4Editor.exe!GuardedMainWrapper() [c:\dev\ue4\4.12.5\engine\source\runtime\launch\private\windows\launchwindows.cpp:126]
UE4Editor.exe!WinMain() [c:\dev\ue4\4.12.5\engine\source\runtime\launch\private\windows\launchwindows.cpp:200]
UE4Editor.exe!__scrt_common_main_seh() [f:\dd\vctools\crt\vcstartup\src\startup\exe_common.inl:255]
kernel32.dll
ntdll.dll
ntdll.dll

Is there anything I need to invoke or set in GT to do this correctly? Or is this a bug?

UE4 4.12.5 on Windows 7 x64. GT 1.9.5.2.

Thanks!
Jon
« Last Edit: December 04, 2016, 10:29:14 AM by jvukovich »

John

  • Coherent Labs support
  • Administrator
  • *****
  • Posts: 202
    • View Profile
Re: GEngine->Browse() causes crash
« Reply #1 on: December 15, 2016, 12:03:09 PM »
Hi jvukovich,

We tested your case with our sample and encountered a crash when playing in Editor, due to the flag PKG_PlayInEditor not being set. Setting the flag explicitly fixes the crash, but you will have to check whether this will have further impact in your specific case. Here is the snippet that resolved the crash:

Code: [Select]
	GetWorld()->GetOutermost()->PackageFlags |= PKG_PlayInEditor;

Could share what you are trying to achieve? Are you just trying to change the level? If this crash persists it would be best to open a ticket in our support system since we will need a dump from the crash.

Regards,
John

jvukovich

  • Posts: 29
    • View Profile
Re: GEngine->Browse() causes crash
« Reply #2 on: February 08, 2017, 08:48:07 PM »
Sorry, I completely missed your reply.

I was simply trying to open a new map and was told by some UE4 programmers to use the code above. Since it caused the crash, I am using this instead and it works just fine:

Code: [Select]
UGameplayStatics::OpenLevel((UObject*) GetGameInstance(), FName(TEXT("MAP_Verran")), TEXT("listen"));
Since I have a work around, I won't bother you guys with a support ticket.

Thanks!

Tags: