1
0
mirror of synced 2024-11-29 01:44:31 +01:00

fix: Pasting bytes in hex editor yielding wrong results

Closes #516
This commit is contained in:
WerWolv 2022-05-29 19:00:21 +02:00
parent f1b2d5881e
commit 4701b1b67c

View File

@ -1016,7 +1016,7 @@ namespace hex::plugin::builtin {
if (clipboard.length() % 2 != 0) return;
// Convert hex string to bytes
std::vector<u8> buffer = hex::decodeByteString(clipboard);
std::vector<u8> buffer = crypt::decode16(clipboard);
// Write bytes
provider->write(selection.getStartAddress() + provider->getBaseAddress() + provider->getCurrentPageAddress(), buffer.data(), std::min(selection.size, buffer.size()));