EmbeddedPkg/Ebl: eliminate deprecated string function calls
Get rid of calls to unsafe string functions. These are deprecated and may be removed in the future. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Reviewed-by: Laszlo Ersek <lersek@redhat.com> Reviewed-by: Leif Lindholm <leif.lindholm@linaro.org>
This commit is contained in:
@@ -116,7 +116,8 @@ EblDirCmd (
|
||||
UnicodeFileName[0] = '\0';
|
||||
MatchSubString = &UnicodeFileName[0];
|
||||
if (Argc > 2) {
|
||||
AsciiStrToUnicodeStr (Argv[2], UnicodeFileName);
|
||||
AsciiStrToUnicodeStrS (Argv[2], UnicodeFileName,
|
||||
ARRAY_SIZE (UnicodeFileName));
|
||||
if (UnicodeFileName[0] == '*') {
|
||||
// Handle *Name substring matching
|
||||
MatchSubString = &UnicodeFileName[1];
|
||||
@@ -231,7 +232,7 @@ EblDirCmd (
|
||||
MatchSubString = NULL;
|
||||
UnicodeFileName[0] = '\0';
|
||||
if (Argc > 2) {
|
||||
AsciiStrToUnicodeStr (Argv[2], UnicodeFileName);
|
||||
AsciiStrToUnicodeStrS (Argv[2], UnicodeFileName, MAX_CMD_LINE);
|
||||
if (UnicodeFileName[0] == '*') {
|
||||
MatchSubString = &UnicodeFileName[1];
|
||||
}
|
||||
|
Reference in New Issue
Block a user