summaryrefslogtreecommitdiffstatshomepage
path: root/3rdparty/lzma/C/Xz.c
diff options
context:
space:
mode:
Diffstat (limited to '3rdparty/lzma/C/Xz.c')
-rw-r--r--3rdparty/lzma/C/Xz.c12
1 files changed, 7 insertions, 5 deletions
diff --git a/3rdparty/lzma/C/Xz.c b/3rdparty/lzma/C/Xz.c
index 18caba2c15b..1ef6878252c 100644
--- a/3rdparty/lzma/C/Xz.c
+++ b/3rdparty/lzma/C/Xz.c
@@ -1,13 +1,15 @@
/* Xz.c - Xz
-2009-04-15 : Igor Pavlov : Public domain */
+2015-05-01 : Igor Pavlov : Public domain */
+
+#include "Precomp.h"
#include "7zCrc.h"
#include "CpuArch.h"
#include "Xz.h"
#include "XzCrc64.h"
-Byte XZ_SIG[XZ_SIG_SIZE] = { 0xFD, '7', 'z', 'X', 'Z', 0 };
-Byte XZ_FOOTER_SIG[XZ_FOOTER_SIG_SIZE] = { 'Y', 'Z' };
+const Byte XZ_SIG[XZ_SIG_SIZE] = { 0xFD, '7', 'z', 'X', 'Z', 0 };
+const Byte XZ_FOOTER_SIG[XZ_FOOTER_SIG_SIZE] = { 'Y', 'Z' };
unsigned Xz_WriteVarInt(Byte *buf, UInt64 v)
{
@@ -38,11 +40,11 @@ void Xz_Free(CXzStream *p, ISzAlloc *alloc)
unsigned XzFlags_GetCheckSize(CXzStreamFlags f)
{
- int t = XzFlags_GetCheckType(f);
+ unsigned t = XzFlags_GetCheckType(f);
return (t == 0) ? 0 : (4 << ((t - 1) / 3));
}
-void XzCheck_Init(CXzCheck *p, int mode)
+void XzCheck_Init(CXzCheck *p, unsigned mode)
{
p->mode = mode;
switch (mode)