/** @file\r
Implementation of interfaces function for EFI_HII_CONFIG_ROUTING_PROTOCOL.\r
\r
-Copyright (c) 2007 - 2013, Intel Corporation. All rights reserved.<BR>\r
+Copyright (c) 2007 - 2014, 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
//\r
// If ConfigHdr has name field and varstore not has name, return FALSE.\r
//\r
- if (Name == NULL && StrStr (ConfigHdr, L"NAME=&") == NULL) {\r
+ if (Name == NULL && ConfigHdr != NULL && StrStr (ConfigHdr, L"NAME=&") == NULL) {\r
return FALSE;\r
}\r
\r
// No matched varstore is found and directly return.\r
//\r
goto Done;\r
- break;\r
\r
default:\r
break;\r
}\r
}\r
-\r
Done:\r
if (HiiFormPackage != NULL) {\r
FreePool (HiiFormPackage);\r
IFR_BLOCK_DATA *NextBlockData;\r
UINTN Length;\r
\r
+ TmpBuffer = NULL;\r
+\r
//\r
// Init RequestBlockArray\r
//\r
\r
Status = GetFormPackageData (DataBaseRecord, &HiiFormPackage, &PackageSize);\r
if (EFI_ERROR (Status)) {\r
- return Status;\r
+ goto Done;\r
}\r
\r
//\r
if ((DevicePathPkg = Database->PackageList->DevicePathPkg) != NULL) {\r
CurrentDevicePath = DevicePathPkg + sizeof (EFI_HII_PACKAGE_HEADER);\r
DevicePathSize = GetDevicePathSize ((EFI_DEVICE_PATH_PROTOCOL *) CurrentDevicePath);\r
- if ((CompareMem (DevicePath,CurrentDevicePath,DevicePathSize) == 0) && IsThisPackageList(Database, Request)) {\r
+ if ((CompareMem (DevicePath,CurrentDevicePath,DevicePathSize) == 0) && IsThisPackageList(Database, ConfigRequest)) {\r
DriverHandle = Database->DriverHandle;\r
HiiHandle = Database->Handle;\r
break;\r
if ((DevicePathPkg = Database->PackageList->DevicePathPkg) != NULL) {\r
CurrentDevicePath = DevicePathPkg + sizeof (EFI_HII_PACKAGE_HEADER);\r
DevicePathSize = GetDevicePathSize ((EFI_DEVICE_PATH_PROTOCOL *) CurrentDevicePath);\r
- if ((CompareMem (DevicePath,CurrentDevicePath,DevicePathSize) == 0) && IsThisPackageList(Database, Configuration)) {\r
+ if ((CompareMem (DevicePath,CurrentDevicePath,DevicePathSize) == 0) && IsThisPackageList(Database, ConfigResp)) {\r
DriverHandle = Database->DriverHandle;\r
break;\r
}\r
);\r
}\r
if (EFI_ERROR (Status)) {\r
+ ASSERT (AccessProgress != NULL);\r
//\r
// AccessProgress indicates the parsing progress on <ConfigResp>.\r
// Map it to the progress on <MultiConfigResp> then return it.\r
CHAR16 *TemString;\r
CHAR16 TemChar;\r
\r
+ TmpBuffer = NULL;\r
+\r
if (This == NULL || Progress == NULL || Config == NULL) {\r
return EFI_INVALID_PARAMETER;\r
}\r
}\r
if (*StringPtr == 0) {\r
*Progress = StringPtr;\r
- Status = EFI_SUCCESS;\r
\r
AppendToMultiString(Config, ConfigRequest);\r
HiiToLower (*Config);\r
\r
- goto Exit;\r
+ return EFI_SUCCESS;\r
}\r
//\r
// Skip '&'\r
UINTN BufferSize;\r
UINTN MaxBlockSize;\r
\r
+ TmpBuffer = NULL;\r
+\r
if (This == NULL || BlockSize == NULL || Progress == NULL) {\r
return EFI_INVALID_PARAMETER;\r
}\r