mirror of
https://github.com/RPCS3/rpcs3.git
synced 2025-07-03 21:41:26 +12:00
patch_manager: check if address has hex format
This commit is contained in:
parent
4d26535758
commit
b04bd5fa74
1 changed files with 7 additions and 0 deletions
|
@ -464,6 +464,13 @@ bool patch_engine::add_patch_data(YAML::Node node, patch_info& info, u32 modifie
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (!addr_node.Scalar().starts_with("0x"))
|
||||||
|
{
|
||||||
|
append_log_message(log_messages, fmt::format("Skipping patch node %s. Address element has wrong format %s. (key: %s, location: %s)", info.description, addr_node.Scalar(), info.hash, get_yaml_node_location(node)));
|
||||||
|
patch_log.error("Skipping patch node %s. Address element has wrong format %s. (key: %s, location: %s)", info.description, addr_node.Scalar(), info.hash, get_yaml_node_location(node));
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
struct patch_data p_data{};
|
struct patch_data p_data{};
|
||||||
p_data.type = type;
|
p_data.type = type;
|
||||||
p_data.offset = addr_node.as<u32>(0) + modifier;
|
p_data.offset = addr_node.as<u32>(0) + modifier;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue