This function converts an input device structure to a Unicode string. @param DevPath A pointer to the device path structure. @return A new allocated Unicode string that represents the device path. **/
| 1628 | |
| 1629 | **/ |
| 1630 | XStringW DevicePathToXStringW ( |
| 1631 | IN EFI_DEVICE_PATH_PROTOCOL *DevPath |
| 1632 | ) |
| 1633 | { |
| 1634 | CHAR16* DevicePathStr = ConvertDevicePathToText (DevPath, TRUE, TRUE); |
| 1635 | XStringW returnValue; |
| 1636 | returnValue.stealValueFrom(DevicePathStr); // do not FreePool FilePath, it's now owned by returnValue |
| 1637 | return returnValue; |
| 1638 | |
| 1639 | } |
| 1640 | |
| 1641 | // |
| 1642 | // Aptio UEFI returns File DevPath as 2 nodes (dir, file) |
no test coverage detected