summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorjcarsey <jcarsey@6f19259b-4bc3-4df7-8a09-765794883524>2013-05-07 17:57:58 +0000
committerjcarsey <jcarsey@6f19259b-4bc3-4df7-8a09-765794883524>2013-05-07 17:57:58 +0000
commite755a4ca10aad316c3620223206d63982793b26c (patch)
treee4a4b5e33ab73804e4fff339d7de05562afc9241
parent5e5bb2a9baefcd2f231696ea94576dab5565fbfb (diff)
downloadedk2-e755a4ca10aad316c3620223206d63982793b26c.zip
edk2-e755a4ca10aad316c3620223206d63982793b26c.tar.gz
edk2-e755a4ca10aad316c3620223206d63982793b26c.tar.bz2
ShellPkg: Fixed build error 'variable set but not used'
GCC toolchain cannot build ShellPkg. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Harry Liebel <Harry.Liebel@arm.com> Signed-off-by: Olivier Martin <Olivier.Martin@arm.com> Reviewed-by: Jaben Carsey <Jaben.Carsey@intel.com> git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@14326 6f19259b-4bc3-4df7-8a09-765794883524
-rw-r--r--ShellPkg/Application/Shell/ShellProtocol.c2
-rw-r--r--ShellPkg/Library/UefiShellDebug1CommandsLib/Bcfg.c4
-rw-r--r--ShellPkg/Library/UefiShellDebug1CommandsLib/EditInputBar.c8
-rw-r--r--ShellPkg/Library/UefiShellDebug1CommandsLib/HexEdit/BufferImage.c25
-rw-r--r--ShellPkg/Library/UefiShellDebug1CommandsLib/HexEdit/DiskImage.c13
-rw-r--r--ShellPkg/Library/UefiShellDebug1CommandsLib/HexEdit/HexEdit.c6
-rw-r--r--ShellPkg/Library/UefiShellDebug1CommandsLib/HexEdit/MainHexEditor.c3
-rw-r--r--ShellPkg/Library/UefiShellDebug1CommandsLib/HexEdit/MemImage.c6
-rw-r--r--ShellPkg/Library/UefiShellDebug1CommandsLib/Mm.c2
-rw-r--r--ShellPkg/Library/UefiShellDebug1CommandsLib/Pci.c2
-rw-r--r--ShellPkg/Library/UefiShellDebug1CommandsLib/UefiShellDebug1CommandsLib.c2
-rw-r--r--ShellPkg/Library/UefiShellDriver1CommandsLib/Dh.c2
-rw-r--r--ShellPkg/Library/UefiShellInstall1CommandsLib/Bcfg.c4
-rw-r--r--ShellPkg/Library/UefiShellLevel1CommandsLib/If.c5
-rw-r--r--ShellPkg/Library/UefiShellLevel2CommandsLib/Cp.c6
-rw-r--r--ShellPkg/Library/UefiShellLevel2CommandsLib/Load.c2
-rw-r--r--ShellPkg/Library/UefiShellLevel2CommandsLib/Map.c2
-rw-r--r--ShellPkg/Library/UefiShellLevel2CommandsLib/Mv.c3
-rw-r--r--ShellPkg/Library/UefiShellLevel2CommandsLib/Rm.c5
-rw-r--r--ShellPkg/Library/UefiShellLevel2CommandsLib/TimeDate.c7
-rw-r--r--ShellPkg/Library/UefiShellLevel3CommandsLib/Cls.c9
-rw-r--r--ShellPkg/Library/UefiShellLevel3CommandsLib/Help.c2
22 files changed, 15 insertions, 105 deletions
diff --git a/ShellPkg/Application/Shell/ShellProtocol.c b/ShellPkg/Application/Shell/ShellProtocol.c
index 68d4fb4..c5b836a 100644
--- a/ShellPkg/Application/Shell/ShellProtocol.c
+++ b/ShellPkg/Application/Shell/ShellProtocol.c
@@ -994,7 +994,6 @@ InternalOpenFileDevicePath(
SHELL_FILE_HANDLE ShellHandle;
EFI_FILE_PROTOCOL *Handle1;
EFI_FILE_PROTOCOL *Handle2;
- EFI_DEVICE_PATH_PROTOCOL *DpCopy;
FILEPATH_DEVICE_PATH *AlignedNode;
if (FileHandle == NULL) {
@@ -1004,7 +1003,6 @@ InternalOpenFileDevicePath(
Handle1 = NULL;
Handle2 = NULL;
Handle = NULL;
- DpCopy = DevicePath;
ShellHandle = NULL;
FilePathNode = NULL;
AlignedNode = NULL;
diff --git a/ShellPkg/Library/UefiShellDebug1CommandsLib/Bcfg.c b/ShellPkg/Library/UefiShellDebug1CommandsLib/Bcfg.c
index 095a946..c26fad7 100644
--- a/ShellPkg/Library/UefiShellDebug1CommandsLib/Bcfg.c
+++ b/ShellPkg/Library/UefiShellDebug1CommandsLib/Bcfg.c
@@ -293,7 +293,7 @@ BcfgAddDebug1(
EFI_STATUS Status;
EFI_DEVICE_PATH_PROTOCOL *DevicePath;
EFI_DEVICE_PATH_PROTOCOL *FilePath;
- EFI_DEVICE_PATH_PROTOCOL *FileNode;
+ /* EFI_DEVICE_PATH_PROTOCOL *FileNode; */
CHAR16 *Str;
UINT8 *TempByteBuffer;
UINT8 *TempByteStart;
@@ -328,7 +328,7 @@ BcfgAddDebug1(
Str = NULL;
FilePath = NULL;
- FileNode = NULL;
+ /* FileNode = NULL; */
FileList = NULL;
Handles = NULL;
ShellStatus = SHELL_SUCCESS;
diff --git a/ShellPkg/Library/UefiShellDebug1CommandsLib/EditInputBar.c b/ShellPkg/Library/UefiShellDebug1CommandsLib/EditInputBar.c
index 978ce7f..649ed57 100644
--- a/ShellPkg/Library/UefiShellDebug1CommandsLib/EditInputBar.c
+++ b/ShellPkg/Library/UefiShellDebug1CommandsLib/EditInputBar.c
@@ -133,8 +133,6 @@ InputBarRefresh (
UINTN Size;
EFI_STATUS Status;
BOOLEAN NoDisplay;
- UINTN Limit;
- UINTN mPromptLen;
UINTN EventIndex;
UINTN CursorRow;
UINTN CursorCol;
@@ -165,12 +163,6 @@ InputBarRefresh (
ShellPrintHiiEx(-1, -1, NULL, STRING_TOKEN(STR_EDIT_LIBINPUTBAR_MAININPUTBAR), gShellDebug1HiiHandle, mPrompt);
//
- // that's the maximum input length that can be displayed on screen
- //
- mPromptLen = StrLen (mPrompt);
- Limit = LastColumn - mPromptLen;
-
- //
// this is a selection mPrompt, cursor will stay in edit area
// actually this is for search , search/replace
//
diff --git a/ShellPkg/Library/UefiShellDebug1CommandsLib/HexEdit/BufferImage.c b/ShellPkg/Library/UefiShellDebug1CommandsLib/HexEdit/BufferImage.c
index 4692632..bfedf58 100644
--- a/ShellPkg/Library/UefiShellDebug1CommandsLib/HexEdit/BufferImage.c
+++ b/ShellPkg/Library/UefiShellDebug1CommandsLib/HexEdit/BufferImage.c
@@ -752,7 +752,6 @@ HBufferImageRefresh (
UINTN StartRow;
UINTN EndRow;
UINTN FStartRow;
- UINTN FEndRow;
UINTN Tmp;
Orig = HMainEditor.ColorAttributes;
@@ -821,7 +820,6 @@ HBufferImageRefresh (
}
FStartRow = StartRow;
- FEndRow = EndRow;
StartRow = 2 + StartRow - HBufferImage.LowVisibleRow;
EndRow = 2 + EndRow - HBufferImage.LowVisibleRow;
@@ -1750,14 +1748,11 @@ HBufferImagePageUp (
VOID
)
{
- HEFI_EDITOR_LINE *Line;
UINTN FRow;
UINTN FCol;
UINTN Gap;
INTN Retreat;
- Line = HBufferImage.CurrentLine;
-
FRow = HBufferImage.BufferPosition.Row;
FCol = HBufferImage.BufferPosition.Column;
@@ -1776,11 +1771,6 @@ HBufferImagePageUp (
Retreat = Gap;
Retreat = -Retreat;
- //
- // get correct line
- //
- Line = HMoveLine (Retreat);
-
FRow -= Gap;
HBufferImageMovePosition (FRow, FCol, HBufferImage.HighBits);
@@ -1798,13 +1788,10 @@ HBufferImageHome (
VOID
)
{
- HEFI_EDITOR_LINE *Line;
UINTN FRow;
UINTN FCol;
BOOLEAN HighBits;
- Line = HBufferImage.CurrentLine;
-
//
// curosr will at the high bit
//
@@ -1918,7 +1905,6 @@ HBufferImageDeleteCharacterFromBuffer (
HEFI_EDITOR_LINE *Line;
LIST_ENTRY *Link;
- UINTN StartRow;
UINTN OldFCol;
UINTN OldFRow;
@@ -1928,11 +1914,6 @@ HBufferImageDeleteCharacterFromBuffer (
EFI_STATUS Status;
- //
- // get the line that start position is at
- //
- StartRow = Pos / 0x10;
-
Size = HBufferImageGetTotalSize ();
if (Size < Count) {
@@ -2054,7 +2035,6 @@ HBufferImageAddCharacterToBuffer (
HEFI_EDITOR_LINE *Line;
LIST_ENTRY *Link;
- UINTN StartRow;
UINTN OldFCol;
UINTN OldFRow;
@@ -2062,11 +2042,6 @@ HBufferImageAddCharacterToBuffer (
UINTN NewPos;
- //
- // get the line that start position is at
- //
- StartRow = Pos / 0x10;
-
Size = HBufferImageGetTotalSize ();
//
diff --git a/ShellPkg/Library/UefiShellDebug1CommandsLib/HexEdit/DiskImage.c b/ShellPkg/Library/UefiShellDebug1CommandsLib/HexEdit/DiskImage.c
index c956f77..a50b52f 100644
--- a/ShellPkg/Library/UefiShellDebug1CommandsLib/HexEdit/DiskImage.c
+++ b/ShellPkg/Library/UefiShellDebug1CommandsLib/HexEdit/DiskImage.c
@@ -181,11 +181,7 @@ HDiskImageRead (
UINTN Bytes;
HEFI_EDITOR_LINE *Line;
- UINT64 ByteOffset;
- EDIT_FILE_TYPE BufferTypeBackup;
-
- BufferTypeBackup = HBufferImage.BufferType;
HBufferImage.BufferType = FileTypeDiskBuffer;
DevicePath = gEfiShellProtocol->GetDevicePathFromMap(DeviceName);
@@ -226,8 +222,6 @@ HDiskImageRead (
return EFI_OUT_OF_RESOURCES;
}
- ByteOffset = MultU64x32 (Offset, BlkIo->Media->BlockSize);
-
//
// read from disk
//
@@ -355,10 +349,6 @@ HDiskImageSave (
VOID *Buffer;
UINTN Bytes;
- UINT64 ByteOffset;
-
- EDIT_FILE_TYPE BufferTypeBackup;
-
//
// if not modified, directly return
//
@@ -366,7 +356,6 @@ HDiskImageSave (
return EFI_SUCCESS;
}
- BufferTypeBackup = HBufferImage.BufferType;
HBufferImage.BufferType = FileTypeDiskBuffer;
DevicePath = gEfiShellProtocol->GetDevicePathFromMap(DeviceName);
@@ -406,8 +395,6 @@ HDiskImageSave (
return Status;
}
- ByteOffset = MultU64x32 (Offset, BlkIo->Media->BlockSize);
-
//
// write the buffer to disk
//
diff --git a/ShellPkg/Library/UefiShellDebug1CommandsLib/HexEdit/HexEdit.c b/ShellPkg/Library/UefiShellDebug1CommandsLib/HexEdit/HexEdit.c
index 68074d4..8cbfd2c 100644
--- a/ShellPkg/Library/UefiShellDebug1CommandsLib/HexEdit/HexEdit.c
+++ b/ShellPkg/Library/UefiShellDebug1CommandsLib/HexEdit/HexEdit.c
@@ -43,25 +43,19 @@ ShellCommandRunHexEdit (
CHAR16 *ProblemParam;
SHELL_STATUS ShellStatus;
LIST_ENTRY *Package;
- CONST CHAR16 *Cwd;
CHAR16 *NewName;
- CHAR16 *Spot;
CONST CHAR16 *Name;
UINTN Offset;
UINTN Size;
- UINT64 LastOffset;
EDIT_FILE_TYPE WhatToDo;
Buffer = NULL;
ShellStatus = SHELL_SUCCESS;
NewName = NULL;
- Cwd = NULL;
Buffer = NULL;
Name = NULL;
- Spot = NULL;
Offset = 0;
Size = 0;
- LastOffset = 0;
WhatToDo = FileTypeNone;
//
diff --git a/ShellPkg/Library/UefiShellDebug1CommandsLib/HexEdit/MainHexEditor.c b/ShellPkg/Library/UefiShellDebug1CommandsLib/HexEdit/MainHexEditor.c
index 09213d8..a40388f 100644
--- a/ShellPkg/Library/UefiShellDebug1CommandsLib/HexEdit/MainHexEditor.c
+++ b/ShellPkg/Library/UefiShellDebug1CommandsLib/HexEdit/MainHexEditor.c
@@ -598,7 +598,6 @@ HMainCommandCut (
)
{
UINTN Index;
- HEFI_EDITOR_LINE *Line;
LIST_ENTRY *Link;
UINT8 *Buffer;
UINTN Count;
@@ -623,8 +622,6 @@ HMainCommandCut (
Link = Link->ForwardLink;
}
- Line = CR (Link, HEFI_EDITOR_LINE, Link, EFI_EDITOR_LINE_LIST);
-
Count = HMainEditor.SelectEnd - HMainEditor.SelectStart + 1;
Buffer = AllocateZeroPool (Count);
if (Buffer == NULL) {
diff --git a/ShellPkg/Library/UefiShellDebug1CommandsLib/HexEdit/MemImage.c b/ShellPkg/Library/UefiShellDebug1CommandsLib/HexEdit/MemImage.c
index 9d44abd..300c67f 100644
--- a/ShellPkg/Library/UefiShellDebug1CommandsLib/HexEdit/MemImage.c
+++ b/ShellPkg/Library/UefiShellDebug1CommandsLib/HexEdit/MemImage.c
@@ -190,9 +190,6 @@ HMemImageRead (
CHAR16 *Str;
HEFI_EDITOR_LINE *Line;
- EDIT_FILE_TYPE BufferTypeBackup;
-
- BufferTypeBackup = HBufferImage.BufferType;
HBufferImage.BufferType = FileTypeMemBuffer;
Buffer = AllocateZeroPool (Size);
@@ -301,8 +298,6 @@ HMemImageSave (
EFI_STATUS Status;
VOID *Buffer;
- EDIT_FILE_TYPE BufferTypeBackup;
-
//
// not modified, so directly return
//
@@ -310,7 +305,6 @@ HMemImageSave (
return EFI_SUCCESS;
}
- BufferTypeBackup = HBufferImage.BufferType;
HBufferImage.BufferType = FileTypeMemBuffer;
Buffer = AllocateZeroPool (Size);
diff --git a/ShellPkg/Library/UefiShellDebug1CommandsLib/Mm.c b/ShellPkg/Library/UefiShellDebug1CommandsLib/Mm.c
index c251ea3..5bb3cff 100644
--- a/ShellPkg/Library/UefiShellDebug1CommandsLib/Mm.c
+++ b/ShellPkg/Library/UefiShellDebug1CommandsLib/Mm.c
@@ -217,7 +217,6 @@ ShellCommandRunMm (
UINT64 Buffer;
UINTN Index;
UINTN Size;
- CHAR16 *AddressStr;
// CHAR16 *ValueStr;
BOOLEAN Complete;
CHAR16 *InputStr;
@@ -245,7 +244,6 @@ ShellCommandRunMm (
Width = EfiPciWidthUint8;
Size = 1;
AccessType = EfiMemory;
- AddressStr = NULL;
// ValueStr = NULL;
Interactive = TRUE;
Package = NULL;
diff --git a/ShellPkg/Library/UefiShellDebug1CommandsLib/Pci.c b/ShellPkg/Library/UefiShellDebug1CommandsLib/Pci.c
index ce55d6e..4ca1fd1 100644
--- a/ShellPkg/Library/UefiShellDebug1CommandsLib/Pci.c
+++ b/ShellPkg/Library/UefiShellDebug1CommandsLib/Pci.c
@@ -2054,13 +2054,11 @@ ShellCommandRunPci (
LIST_ENTRY *Package;
CHAR16 *ProblemParam;
SHELL_STATUS ShellStatus;
- UINTN Size;
CONST CHAR16 *Temp;
ShellStatus = SHELL_SUCCESS;
Status = EFI_SUCCESS;
Address = 0;
- Size = 0;
IoDev = NULL;
HandleBuf = NULL;
Package = NULL;
diff --git a/ShellPkg/Library/UefiShellDebug1CommandsLib/UefiShellDebug1CommandsLib.c b/ShellPkg/Library/UefiShellDebug1CommandsLib/UefiShellDebug1CommandsLib.c
index 1d72ea6..c601abe 100644
--- a/ShellPkg/Library/UefiShellDebug1CommandsLib/UefiShellDebug1CommandsLib.c
+++ b/ShellPkg/Library/UefiShellDebug1CommandsLib/UefiShellDebug1CommandsLib.c
@@ -490,11 +490,9 @@ EditGetDefaultFileName (
{
EFI_STATUS Status;
UINTN Suffix;
- BOOLEAN FoundNewFile;
CHAR16 *FileNameTmp;
Suffix = 0;
- FoundNewFile = FALSE;
do {
FileNameTmp = CatSPrint (NULL, L"NewFile%d.%s", Suffix, Extension);
diff --git a/ShellPkg/Library/UefiShellDriver1CommandsLib/Dh.c b/ShellPkg/Library/UefiShellDriver1CommandsLib/Dh.c
index a0dc139..9947c56 100644
--- a/ShellPkg/Library/UefiShellDriver1CommandsLib/Dh.c
+++ b/ShellPkg/Library/UefiShellDriver1CommandsLib/Dh.c
@@ -674,9 +674,7 @@ DoDhByHandle(
{
CHAR16 *ProtocolInfoString;
SHELL_STATUS ShellStatus;
- EFI_STATUS Status;
- Status = EFI_SUCCESS;
ShellStatus = SHELL_SUCCESS;
ProtocolInfoString = NULL;
diff --git a/ShellPkg/Library/UefiShellInstall1CommandsLib/Bcfg.c b/ShellPkg/Library/UefiShellInstall1CommandsLib/Bcfg.c
index a7a10bf..5dcbfb6 100644
--- a/ShellPkg/Library/UefiShellInstall1CommandsLib/Bcfg.c
+++ b/ShellPkg/Library/UefiShellInstall1CommandsLib/Bcfg.c
@@ -1,7 +1,7 @@
/** @file
Main file for bcfg shell Install1 function.
- Copyright (c) 2010 - 2012, Intel Corporation. All rights reserved.<BR>
+ Copyright (c) 2010 - 2013, Intel Corporation. All rights reserved.<BR>
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -293,7 +293,6 @@ BcfgAddInstall1(
EFI_STATUS Status;
EFI_DEVICE_PATH_PROTOCOL *DevicePath;
EFI_DEVICE_PATH_PROTOCOL *FilePath;
- EFI_DEVICE_PATH_PROTOCOL *FileNode;
CHAR16 *Str;
UINT8 *TempByteBuffer;
UINT8 *TempByteStart;
@@ -328,7 +327,6 @@ BcfgAddInstall1(
Str = NULL;
FilePath = NULL;
- FileNode = NULL;
FileList = NULL;
Handles = NULL;
ShellStatus = SHELL_SUCCESS;
diff --git a/ShellPkg/Library/UefiShellLevel1CommandsLib/If.c b/ShellPkg/Library/UefiShellLevel1CommandsLib/If.c
index 0892731..54ed23b 100644
--- a/ShellPkg/Library/UefiShellLevel1CommandsLib/If.c
+++ b/ShellPkg/Library/UefiShellLevel1CommandsLib/If.c
@@ -662,12 +662,9 @@ BuildNextStatement (
OUT END_TAG_TYPE *EndTag
)
{
- CHAR16 *Buffer;
- UINTN BufferSize;
-
*EndTag = EndTagMax;
- for(Buffer = NULL, BufferSize = 0
+ for(
; ParameterNumber < gEfiShellParametersProtocol->Argc
; ParameterNumber++
) {
diff --git a/ShellPkg/Library/UefiShellLevel2CommandsLib/Cp.c b/ShellPkg/Library/UefiShellLevel2CommandsLib/Cp.c
index 876cb9d..4443212 100644
--- a/ShellPkg/Library/UefiShellLevel2CommandsLib/Cp.c
+++ b/ShellPkg/Library/UefiShellLevel2CommandsLib/Cp.c
@@ -87,6 +87,7 @@ CopySingleFile(
Response = *Resp;
List = NULL;
DestVolumeInfo = NULL;
+ ShellStatus = SHELL_SUCCESS;
ReadSize = PcdGet16(PcdShellFileOperationSize);
// Why bother copying a file to itself
@@ -255,7 +256,7 @@ CopySingleFile(
//
// return
//
- return (SHELL_SUCCESS);
+ return ShellStatus;
}
/**
@@ -537,12 +538,11 @@ ProcessValidateAndCopyFiles(
{
SHELL_STATUS ShellStatus;
EFI_SHELL_FILE_INFO *List;
- EFI_STATUS Status;
EFI_FILE_INFO *FileInfo;
List = NULL;
- Status = ShellOpenFileMetaArg((CHAR16*)DestDir, EFI_FILE_MODE_READ, &List);
+ ShellOpenFileMetaArg((CHAR16*)DestDir, EFI_FILE_MODE_READ, &List);
if (List != NULL && List->Link.ForwardLink != List->Link.BackLink) {
ShellPrintHiiEx(-1, -1, NULL, STRING_TOKEN (STR_GEN_MARG_ERROR), gShellLevel2HiiHandle, DestDir);
ShellStatus = SHELL_INVALID_PARAMETER;
diff --git a/ShellPkg/Library/UefiShellLevel2CommandsLib/Load.c b/ShellPkg/Library/UefiShellLevel2CommandsLib/Load.c
index 5edb9d7..98ef4b8 100644
--- a/ShellPkg/Library/UefiShellLevel2CommandsLib/Load.c
+++ b/ShellPkg/Library/UefiShellLevel2CommandsLib/Load.c
@@ -81,13 +81,11 @@ LoadDriver(
{
EFI_HANDLE LoadedDriverHandle;
EFI_STATUS Status;
- EFI_DEVICE_PATH_PROTOCOL *Node;
EFI_DEVICE_PATH_PROTOCOL *FilePath;
EFI_LOADED_IMAGE_PROTOCOL *LoadedDriverImage;
LoadedDriverImage = NULL;
FilePath = NULL;
- Node = NULL;
LoadedDriverHandle = NULL;
Status = EFI_SUCCESS;
diff --git a/ShellPkg/Library/UefiShellLevel2CommandsLib/Map.c b/ShellPkg/Library/UefiShellLevel2CommandsLib/Map.c
index a1f9448..78e432b 100644
--- a/ShellPkg/Library/UefiShellLevel2CommandsLib/Map.c
+++ b/ShellPkg/Library/UefiShellLevel2CommandsLib/Map.c
@@ -1025,7 +1025,6 @@ ShellCommandRunMap (
CONST CHAR16 *SName;
CONST CHAR16 *Mapping;
EFI_HANDLE MapAsHandle;
- CONST EFI_DEVICE_PATH_PROTOCOL *DevPath;
SHELL_STATUS ShellStatus;
BOOLEAN SfoMode;
BOOLEAN ConstMode;
@@ -1037,7 +1036,6 @@ ShellCommandRunMap (
ProblemParam = NULL;
Mapping = NULL;
SName = NULL;
- DevPath = NULL;
ShellStatus = SHELL_SUCCESS;
MapAsHandle = NULL;
diff --git a/ShellPkg/Library/UefiShellLevel2CommandsLib/Mv.c b/ShellPkg/Library/UefiShellLevel2CommandsLib/Mv.c
index 541e782..11abee0 100644
--- a/ShellPkg/Library/UefiShellLevel2CommandsLib/Mv.c
+++ b/ShellPkg/Library/UefiShellLevel2CommandsLib/Mv.c
@@ -135,7 +135,6 @@ GetDestinationLocation(
{
EFI_SHELL_FILE_INFO *DestList;
EFI_SHELL_FILE_INFO *Node;
- EFI_STATUS Status;
CHAR16 *DestPath;
CHAR16 *TempLocation;
UINTN NewSize;
@@ -159,7 +158,7 @@ GetDestinationLocation(
//
// get the destination path
//
- Status = ShellOpenFileMetaArg((CHAR16*)DestDir, EFI_FILE_MODE_WRITE|EFI_FILE_MODE_READ|EFI_FILE_MODE_CREATE, &DestList);
+ ShellOpenFileMetaArg((CHAR16*)DestDir, EFI_FILE_MODE_WRITE|EFI_FILE_MODE_READ|EFI_FILE_MODE_CREATE, &DestList);
if (DestList == NULL || IsListEmpty(&DestList->Link)) {
//
// Not existing... must be renaming
diff --git a/ShellPkg/Library/UefiShellLevel2CommandsLib/Rm.c b/ShellPkg/Library/UefiShellLevel2CommandsLib/Rm.c
index d167b36..2eb54d3 100644
--- a/ShellPkg/Library/UefiShellLevel2CommandsLib/Rm.c
+++ b/ShellPkg/Library/UefiShellLevel2CommandsLib/Rm.c
@@ -33,7 +33,6 @@ IsDirectoryEmpty (
IN EFI_HANDLE FileHandle
)
{
- EFI_STATUS Status;
EFI_FILE_INFO *FileInfo;
BOOLEAN NoFile;
BOOLEAN RetVal;
@@ -41,9 +40,9 @@ IsDirectoryEmpty (
RetVal = TRUE;
NoFile = FALSE;
- for (Status = FileHandleFindFirstFile(FileHandle, &FileInfo)
+ for (FileHandleFindFirstFile(FileHandle, &FileInfo)
; !NoFile
- ; Status = FileHandleFindNextFile(FileHandle, FileInfo, &NoFile)
+ ; FileHandleFindNextFile(FileHandle, FileInfo, &NoFile)
){
if (StrStr(FileInfo->FileName, L".") != FileInfo->FileName
&&StrStr(FileInfo->FileName, L"..") != FileInfo->FileName) {
diff --git a/ShellPkg/Library/UefiShellLevel2CommandsLib/TimeDate.c b/ShellPkg/Library/UefiShellLevel2CommandsLib/TimeDate.c
index dfe03fd..e5596ba 100644
--- a/ShellPkg/Library/UefiShellLevel2CommandsLib/TimeDate.c
+++ b/ShellPkg/Library/UefiShellLevel2CommandsLib/TimeDate.c
@@ -378,7 +378,6 @@ ShellCommandRunTime (
{
EFI_STATUS Status;
LIST_ENTRY *Package;
- CHAR16 *Message;
EFI_TIME TheTime;
CHAR16 *ProblemParam;
SHELL_STATUS ShellStatus;
@@ -387,13 +386,11 @@ ShellCommandRunTime (
CONST CHAR16 *TempLocation;
UINTN TzMinutes;
- ShellStatus = SHELL_SUCCESS;
- ProblemParam = NULL;
-
//
// Initialize variables
//
- Message = NULL;
+ ShellStatus = SHELL_SUCCESS;
+ ProblemParam = NULL;
//
// initialize the shell lib (we must be in non-auto-init...)
diff --git a/ShellPkg/Library/UefiShellLevel3CommandsLib/Cls.c b/ShellPkg/Library/UefiShellLevel3CommandsLib/Cls.c
index dec2477..8cb1aed 100644
--- a/ShellPkg/Library/UefiShellLevel3CommandsLib/Cls.c
+++ b/ShellPkg/Library/UefiShellLevel3CommandsLib/Cls.c
@@ -29,21 +29,18 @@ ShellCommandRunCls (
{
EFI_STATUS Status;
LIST_ENTRY *Package;
- CHAR16 *Message;
UINTN Background;
UINTN ForeColor;
CHAR16 *ProblemParam;
SHELL_STATUS ShellStatus;
CONST CHAR16 *Param1;
- ShellStatus = SHELL_SUCCESS;
- ProblemParam = NULL;
- Background = 0;
-
//
// Initialize variables
//
- Message = NULL;
+ ShellStatus = SHELL_SUCCESS;
+ ProblemParam = NULL;
+ Background = 0;
//
// initialize the shell lib (we must be in non-auto-init...)
diff --git a/ShellPkg/Library/UefiShellLevel3CommandsLib/Help.c b/ShellPkg/Library/UefiShellLevel3CommandsLib/Help.c
index c4acc0b..cd03ff7 100644
--- a/ShellPkg/Library/UefiShellLevel3CommandsLib/Help.c
+++ b/ShellPkg/Library/UefiShellLevel3CommandsLib/Help.c
@@ -41,7 +41,6 @@ ShellCommandRunHelp (
LIST_ENTRY *Package;
CHAR16 *ProblemParam;
SHELL_STATUS ShellStatus;
- CHAR16 *OutText;
CONST COMMAND_LIST *CommandList;
CONST COMMAND_LIST *Node;
CHAR16 *CommandToGetHelpOn;
@@ -53,7 +52,6 @@ ShellCommandRunHelp (
PrintCommandText = TRUE;
ProblemParam = NULL;
ShellStatus = SHELL_SUCCESS;
- OutText = NULL;
CommandToGetHelpOn = NULL;
SectionToGetHelpOn = NULL;
Found = FALSE;