fix: Various build errors

This commit is contained in:
WerWolv
2023-12-08 16:22:36 +01:00
parent 48bc0985d9
commit 878f45dd80
12 changed files with 41 additions and 29 deletions

View File

@@ -43,11 +43,11 @@ namespace hex {
return this->m_patches.rbegin()->first;
}
void resizeRaw(size_t newSize) override {
void resizeRaw(u64 newSize) override {
hex::unused(newSize);
}
void insertRaw(u64 offset, size_t size) override {
void insertRaw(u64 offset, u64 size) override {
std::vector<std::pair<u64, u8>> patchesToMove;
for (auto &[address, value] : this->m_patches) {
@@ -61,7 +61,7 @@ namespace hex {
this->m_patches.insert({ address + size, value });
}
void removeRaw(u64 offset, size_t size) override {
void removeRaw(u64 offset, u64 size) override {
std::vector<std::pair<u64, u8>> patchesToMove;
for (auto &[address, value] : this->m_patches) {

View File

@@ -71,6 +71,20 @@ namespace hex {
return { data + index + 1 };
}
std::string toLower(std::string string) {
for (char &c : string)
c = std::tolower(c);
return string;
}
std::string toUpper(std::string string) {
for (char &c : string)
c = std::toupper(c);
return string;
}
std::vector<u8> parseHexString(std::string string) {
if (string.empty())
return { };