diff options
author | Star Zeng <star.zeng@intel.com> | 2016-06-15 13:38:35 +0800 |
---|---|---|
committer | Hao Wu <hao.a.wu@intel.com> | 2016-07-07 14:05:14 +0800 |
commit | 72c1b49bdfe8372675d310c5015bf14f2b3706e3 (patch) | |
tree | b7d86e08bd0a1a70269c0104051f8d90eac4c972 | |
parent | d83399e08656dc8c951caf60b7043846cb9539cd (diff) | |
download | edk2-platforms-72c1b49bdfe8372675d310c5015bf14f2b3706e3.tar.xz |
PerformancePkg: Replace UnicodeStrToAsciiStr/AsciiStrToUnicodeStr
It is the follow up of 3ab41b7a325ca11a12b42f5ad1661c4b6791cb49
to replace UnicodeStrToAsciiStr/AsciiStrToUnicodeStr with
UnicodeStrToAsciiStrS/AsciiStrToUnicodeStrS.
Cc: Jiewen Yao <jiewen.yao@intel.com>
Cc: Liming Gao <liming.gao@intel.com>
Cc: Jaben Carsey <jaben.carsey@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Star Zeng <star.zeng@intel.com>
Reviewed-by: Jaben Carsey <jaben.carsey@intel.com>
(cherry picked from commit 23cfa2b9f0d08d744ec66b05140129464bf12ef9)
-rw-r--r-- | PerformancePkg/Dp_App/DpTrace.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/PerformancePkg/Dp_App/DpTrace.c b/PerformancePkg/Dp_App/DpTrace.c index 1ba2b72ba4..e3dd19d2c0 100644 --- a/PerformancePkg/Dp_App/DpTrace.c +++ b/PerformancePkg/Dp_App/DpTrace.c @@ -210,8 +210,8 @@ DumpAllTrace( ++Count; // Count the number of records printed
// If Handle is non-zero, see if we can determine a name for the driver
- AsciiStrToUnicodeStr (Measurement.Module, mGaugeString); // Use Module by default
- AsciiStrToUnicodeStr (Measurement.Token, mUnicodeToken);
+ AsciiStrToUnicodeStrS (Measurement.Module, mGaugeString, sizeof (mGaugeString) / sizeof (mGaugeString[0])); // Use Module by default
+ AsciiStrToUnicodeStrS (Measurement.Token, mUnicodeToken, sizeof (mUnicodeToken) / sizeof (mUnicodeToken[0]));
if (Measurement.Handle != NULL) {
// See if the Handle is in the HandleBuffer
for (TIndex = 0; TIndex < (Size / sizeof(HandleBuffer[0])); TIndex++) {
@@ -578,7 +578,7 @@ ProcessHandles( continue;
}
mGaugeString[0] = 0; // Empty driver name by default
- AsciiStrToUnicodeStr (Measurement.Token, mUnicodeToken);
+ AsciiStrToUnicodeStrS (Measurement.Token, mUnicodeToken, sizeof (mUnicodeToken) / sizeof (mUnicodeToken[0]));
// See if the Handle is in the HandleBuffer
for (Index = 0; Index < (Size / sizeof(HandleBuffer[0])); Index++) {
if (Measurement.Handle == HandleBuffer[Index]) {
@@ -742,8 +742,8 @@ ProcessGlobal( &Measurement.EndTimeStamp,
&Measurement.Identifier)) != 0)
{
- AsciiStrToUnicodeStr (Measurement.Module, mGaugeString);
- AsciiStrToUnicodeStr (Measurement.Token, mUnicodeToken);
+ AsciiStrToUnicodeStrS (Measurement.Module, mGaugeString, sizeof (mGaugeString) / sizeof (mGaugeString[0]));
+ AsciiStrToUnicodeStrS (Measurement.Token, mUnicodeToken, sizeof (mUnicodeToken) / sizeof (mUnicodeToken[0]));
mGaugeString[25] = 0;
mUnicodeToken[31] = 0;
if ( ! ( IsPhase( &Measurement) ||
|