🚚 Fix build error

This commit is contained in:
C-3PO 2018-09-14 04:54:11 +02:00
parent 736e92ebd5
commit 12190f0ae8
Signed by: c3po
GPG key ID: 62993C4BB4D86F24
2 changed files with 4 additions and 3 deletions

View file

@ -1,5 +1,6 @@
#pragma once #pragma once
#include <stdbool.h>
#include <stdint.h> #include <stdint.h>
void initFileReader(char path[], unsigned long offset); void initFileReader(char path[], unsigned long offset);

View file

@ -57,7 +57,7 @@ int main(int argc, char *argv[]) {
initFileReader(state.diskName, state.diskOffset); initFileReader(state.diskName, state.diskOffset);
//Skip local file header (30 bytes + additional length) //Skip local file header (30 bytes + additional length)
getBytes(compressedChunk, 30UL); getBytes(compressedChunk, 30UL, false);
//Check that header is correct //Check that header is correct
const uint32_t magic = getUint32(compressedChunk); const uint32_t magic = getUint32(compressedChunk);
if (magic != LOCAL_FILE_HEADER_MAGIC) { if (magic != LOCAL_FILE_HEADER_MAGIC) {
@ -67,12 +67,12 @@ int main(int argc, char *argv[]) {
//Read additional length //Read additional length
const unsigned long additionalLength = getUint16(compressedChunk + 26) + getUint16(compressedChunk + 28); const unsigned long additionalLength = getUint16(compressedChunk + 26) + getUint16(compressedChunk + 28);
if (additionalLength > 0UL) { if (additionalLength > 0UL) {
getBytes(NULL, additionalLength); getBytes(NULL, additionalLength, false);
} }
//If file is encrypted, skip 12-byte encryption header //If file is encrypted, skip 12-byte encryption header
if (state.isEncrypted) { if (state.isEncrypted) {
getBytes(compressedChunk, ENCRYPTION_HEADER_LENGTH); getBytes(compressedChunk, ENCRYPTION_HEADER_LENGTH, false);
decrypt(compressedChunk, ENCRYPTION_HEADER_LENGTH); decrypt(compressedChunk, ENCRYPTION_HEADER_LENGTH);
} }