fix potential memory access violation

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11152 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
ydong10 2010-12-10 11:16:24 +00:00
parent 8a2d49964e
commit d04608758d
1 changed files with 1 additions and 1 deletions

View File

@ -802,7 +802,7 @@ CallDeviceManager (
//
if (mNextShowFormId == NETWORK_DEVICE_FORM_ID) {
String = HiiGetString (HiiHandle, STRING_TOKEN (STR_FORM_NETWORK_DEVICE_TITLE), NULL);
NewStringLen = StrLen(mSelectedMacAddrString);
NewStringLen = StrLen(mSelectedMacAddrString) * 2;
NewStringLen += (StrLen(String) + 2) * 2;
NewStringTitle = AllocatePool (NewStringLen);
UnicodeSPrint (NewStringTitle, NewStringLen, L"%s %s", String, mSelectedMacAddrString);