When the format of DEVICE_PATH have string, like as:
{DEVICE_PATH("BBS(1,"AB",0)")} have string "AB", will
get the wrong value.
Cc: Liming Gao <liming.gao@intel.com>
Cc: Yonghong Zhu <yonghong.zhu@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Yunhua Feng <yunhuax.feng@intel.com>
Reviewed-by: Yonghong Zhu <yonghong.zhu@intel.com>
Value = (Value << 8) | ((ItemValue >> 8 * I) & 0xff)\r
return Value, RetSize\r
if Value.startswith('DEVICE_PATH(') and Value.endswith(')'):\r
- Value = Value.split('"')[1]\r
+ Value = Value.replace("DEVICE_PATH(", '').rstrip(')')\r
+ Value = Value.strip().strip('"')\r
return ParseDevPathValue(Value)\r
if Value.lower().startswith('0x'):\r
Value = int(Value, 16)\r