Diff of /MyTreeCtrl.cpp [6635e0] .. [558161]  Maximize  Restore

  Switch to side-by-side view

--- a/MyTreeCtrl.cpp
+++ b/MyTreeCtrl.cpp
@@ -19,6 +19,7 @@
 #include "DboxMain.h"
 #include "corelib/ItemData.h"
 #include "corelib/MyString.h"
+#include "corelib/Util.h"
 
 #ifdef _DEBUG
 #define new DEBUG_NEW
@@ -196,7 +197,8 @@
       // we cannot do "SetItemText(ti, treeDispString)" here since Windows will
       // automatically overwrite and update the item text with the contents from 
       // the "ptvinfo->item.pszText" buffer.
-      strncpy(ptvinfo->item.pszText, treeDispString, ptvinfo->item.cchTextMax);
+      PWSUtil::strCopy(ptvinfo->item.pszText, ptvinfo->item.cchTextMax,
+                      treeDispString, ptvinfo->item.cchTextMax);
       ptvinfo->item.pszText[ptvinfo->item.cchTextMax - 1] = '\0';
 
       // update the password database record.