summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--ldid.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/ldid.cpp b/ldid.cpp
index 20abec9..8010211 100644
--- a/ldid.cpp
+++ b/ldid.cpp
@@ -2019,7 +2019,9 @@ static std::vector<char> Sign(const uint8_t *prefix, size_t size, std::streambuf
// XXX: this is a miserable fail
std::stringbuf temp;
put(temp, prefix, size);
- copy(buffer, temp);
+ size += copy(buffer, temp);
+ // XXX: this is a stupid hack
+ pad(temp, 0x10 - (size & 0xf));
auto data(temp.str());
HashProxy proxy(hash, save);