blob: 018e3a7d5a08f1fb3eb26013ef7a81eb5f720a91 [file] [log] [blame]
diff --git a/SRC/7zip/Compress/LZMA_Alone/LzmaAlone.cpp b/SRC/7zip/Compress/LZMA_Alone/LzmaAlone.cpp
index b659d8e..6d51370 100755
--- a/SRC/7zip/Compress/LZMA_Alone/LzmaAlone.cpp
+++ b/SRC/7zip/Compress/LZMA_Alone/LzmaAlone.cpp
@@ -403,6 +403,16 @@ int main2(int n, const char *args[])
return 1;
}
}
+ // Add 3 bytes of padding
+ for (int i = 0; i < 3; i++)
+ {
+ Byte b = 0;
+ if (outStream->Write(&b, sizeof(b), 0) != S_OK)
+ {
+ fprintf(stderr, "Write error");
+ return 1;
+ }
+ }
HRESULT result = encoder->Code(inStream, outStream, 0, 0, 0);
if (result == E_OUTOFMEMORY)
{