]> git.proxmox.com Git - mirror_edk2.git/blobdiff - ShellPkg/Library/UefiShellDebug1CommandsLib/DmpStore.c
ShellPkg: Use safe string functions to refine code.
[mirror_edk2.git] / ShellPkg / Library / UefiShellDebug1CommandsLib / DmpStore.c
index 3ae61c9c3fdcdd4aefde8262eebcda9f7cc583c2..d818b9b8d4707d9814dc677c5eef9adf5135bd44 100644 (file)
@@ -2,7 +2,7 @@
   Main file for DmpStore shell Debug1 function.\r
    \r
   (C) Copyright 2013-2015 Hewlett-Packard Development Company, L.P.<BR>\r
-  Copyright (c) 2005 - 2014, Intel Corporation. All rights reserved.<BR>\r
+  Copyright (c) 2005 - 2015, Intel Corporation. All rights reserved.<BR>\r
   This program and the accompanying materials\r
   are licensed and made available under the terms and conditions of the BSD License\r
   which accompanies this distribution.  The full text of the license may be found at\r
@@ -406,7 +406,7 @@ CascadeProcessVariables (
     FoundVarName = AllocateZeroPool (NameSize);\r
     if (FoundVarName != NULL) {\r
       if (PrevName != NULL) {\r
-        StrnCpy(FoundVarName, PrevName, NameSize/sizeof(CHAR16)-1);\r
+        StrCpyS(FoundVarName, NameSize/sizeof(CHAR16), PrevName);\r
       }\r
 \r
       Status = gRT->GetNextVariableName (&NameSize, FoundVarName, &FoundVarGuid);\r