summaryrefslogtreecommitdiff
path: root/EdkCompatibilityPkg
diff options
context:
space:
mode:
authorlgao4 <lgao4@6f19259b-4bc3-4df7-8a09-765794883524>2010-06-28 10:26:41 +0000
committerlgao4 <lgao4@6f19259b-4bc3-4df7-8a09-765794883524>2010-06-28 10:26:41 +0000
commit97c0d02fd653fe210b6a19771d3442abfae87066 (patch)
tree01b862a03b15b9763fff5a2fc3bb63dcb1dca2d5 /EdkCompatibilityPkg
parent9053bc517ea77b9780830bf08b966979eff1cb0f (diff)
downloadedk2-platforms-97c0d02fd653fe210b6a19771d3442abfae87066.tar.xz
Remove unnecessary volatile for local Index variable.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@10608 6f19259b-4bc3-4df7-8a09-765794883524
Diffstat (limited to 'EdkCompatibilityPkg')
-rw-r--r--EdkCompatibilityPkg/Foundation/Library/EdkIIGlueLib/Library/BaseUefiDecompressLib/BaseUefiDecompressLib.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/EdkCompatibilityPkg/Foundation/Library/EdkIIGlueLib/Library/BaseUefiDecompressLib/BaseUefiDecompressLib.c b/EdkCompatibilityPkg/Foundation/Library/EdkIIGlueLib/Library/BaseUefiDecompressLib/BaseUefiDecompressLib.c
index cc491238fe..a57b0b9e37 100644
--- a/EdkCompatibilityPkg/Foundation/Library/EdkIIGlueLib/Library/BaseUefiDecompressLib/BaseUefiDecompressLib.c
+++ b/EdkCompatibilityPkg/Foundation/Library/EdkIIGlueLib/Library/BaseUefiDecompressLib/BaseUefiDecompressLib.c
@@ -142,7 +142,7 @@ GlueMakeTable (
UINT16 Start[18];
UINT16 *Pointer;
UINT16 Index3;
- volatile UINT16 Index;
+ UINT16 Index;
UINT16 Len;
UINT16 Char;
UINT16 JuBits;
@@ -155,7 +155,7 @@ GlueMakeTable (
//
// TableBits should not be greater than 16.
//
- if (TableBits > 16) {
+ if (TableBits >= (sizeof (Count)/sizeof (UINT16))) {
return (UINT16) BAD_TABLE;
}
@@ -170,7 +170,7 @@ GlueMakeTable (
//
// Count array index should not be greater than or equal to its size.
//
- if (BitLen[Index] <= 16) {
+ if (BitLen[Index] < (sizeof (Count)/sizeof (UINT16))) {
Count[BitLen[Index]]++;
} else {
return (UINT16) BAD_TABLE;