/** @file\r
Platform BDS customizations.\r
\r
- Copyright (c) 2004 - 2012, Intel Corporation. All rights reserved.<BR>\r
+ Copyright (c) 2004 - 2013, 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
// Print Device Path\r
//\r
DevPathStr = DevicePathToStr(DevicePath);\r
- DEBUG((\r
- EFI_D_INFO,\r
- "BdsPlatform.c+%d: COM%d DevPath: %s\n",\r
- __LINE__,\r
- gPnp16550ComPortDeviceNode.UID + 1,\r
- DevPathStr\r
- ));\r
- FreePool(DevPathStr);\r
+ if (DevPathStr != NULL) {\r
+ DEBUG((\r
+ EFI_D_INFO,\r
+ "BdsPlatform.c+%d: COM%d DevPath: %s\n",\r
+ __LINE__,\r
+ gPnp16550ComPortDeviceNode.UID + 1,\r
+ DevPathStr\r
+ ));\r
+ FreePool(DevPathStr);\r
+ }\r
\r
BdsLibUpdateConsoleVariable (VarConsoleOut, DevicePath, NULL);\r
BdsLibUpdateConsoleVariable (VarConsoleInp, DevicePath, NULL);\r
// Print Device Path\r
//\r
DevPathStr = DevicePathToStr(DevicePath);\r
- DEBUG((\r
- EFI_D_INFO,\r
- "BdsPlatform.c+%d: COM%d DevPath: %s\n",\r
- __LINE__,\r
- gPnp16550ComPortDeviceNode.UID + 1,\r
- DevPathStr\r
- ));\r
- FreePool(DevPathStr);\r
+ if (DevPathStr != NULL) {\r
+ DEBUG((\r
+ EFI_D_INFO,\r
+ "BdsPlatform.c+%d: COM%d DevPath: %s\n",\r
+ __LINE__,\r
+ gPnp16550ComPortDeviceNode.UID + 1,\r
+ DevPathStr\r
+ ));\r
+ FreePool(DevPathStr);\r
+ }\r
\r
BdsLibUpdateConsoleVariable (VarConsoleOut, DevicePath, NULL);\r
BdsLibUpdateConsoleVariable (VarConsoleInp, DevicePath, NULL);\r
// Print Device Path\r
//\r
DevPathStr = DevicePathToStr (DevicePath);\r
- DEBUG((\r
- EFI_D_INFO,\r
- "Found Mass Storage device: %s\n",\r
- DevPathStr\r
- ));\r
- FreePool(DevPathStr);\r
+ if (DevPathStr != NULL) {\r
+ DEBUG((\r
+ EFI_D_INFO,\r
+ "Found Mass Storage device: %s\n",\r
+ DevPathStr\r
+ ));\r
+ FreePool(DevPathStr);\r
+ }\r
\r
Status = gBS->ConnectController (Handle, NULL, NULL, TRUE);\r
if (EFI_ERROR (Status)) {\r