diff UI/UiGame.cpp @ 1983:5cd26f2c6904

small fix
author Ritor1
date Fri, 01 Nov 2013 17:29:49 +0600
parents c1c74df0a33e
children 985fff9fb62d
line wrap: on
line diff
--- a/UI/UiGame.cpp	Fri Nov 01 14:44:06 2013 +0600
+++ b/UI/UiGame.cpp	Fri Nov 01 17:29:49 2013 +0600
@@ -376,7 +376,7 @@
     assert(pNPC->uProfession < sizeof(aNPCProfessionNames) / sizeof(*aNPCProfessionNames.data())); // sometimes buffer overflows; errors emerge both here and in dialogue text
     sprintfex(pTmpBuf.data(), pGlobalTXT_LocalizationStrings[429], pNPC->pName, aNPCProfessionNames[pNPC->uProfession]);//^Pi[%s] %s
   }
-  else
+  else if (pNPC->pName)
     strcpy(pTmpBuf.data(), pNPC->pName);
 
   window.DrawTitleText(pFontArrus, 483, 112, ui_game_dialogue_npc_name_color, pTmpBuf.data(), 3);