Access violation exception

I am planning to integrate one custom dll into unreal engine like this dll linking guide ,
It is simple, When we call dll method it will return a string.

It is giving this exception at random times not in specific cases!!

void ACARPawn::Tick(float Delta)
{
	Super::Tick(Delta);


	try
	{
		string tempstr="something";
			tempstr = string(m_getQueuedMessagesFromDll());

		FString fstringVar = "something";
		fstringVar=tempstr.c_str();

		if(fstringVar == "Foreward")
		{
			MoveForward(2);
		}
		else if(fstringVar == "Reverse")
		{
			MoveForward(-2);
		}
	}

	catch (exception ex)
	{
		UE_LOG(LogTemp, Warning, TEXT("Exception in Tick"));
	}

}

Exception thrown at 0x00007FFF06F67C3B (UE4Editor-Core.dll) in UE4Editor.exe: 0xC0000005: Access violation writing location 0x0000000000000010.