[CABINET] Sync with Wine Staging 3.3. CORE-14434
[reactos.git] / dll / win32 / cabinet / fci.c
index 8139dcd..167ca74 100644 (file)
@@ -30,16 +30,28 @@ There is still some work to be done:
 
 */
 
-#include "cabinet.h"
 
-#include <assert.h>
-#include <fci.h>
 
+#include "config.h"
+
+#include <assert.h>
+#include <stdarg.h>
+#include <stdio.h>
+#include <string.h>
 #ifdef HAVE_ZLIB
 # include <zlib.h>
 #endif
 
-#include <wine/list.h>
+#include "windef.h"
+#include "winbase.h"
+#include "winerror.h"
+#include "wine/winternl.h"
+#include "fci.h"
+#include "cabinet.h"
+#include "wine/list.h"
+#include "wine/debug.h"
+
+WINE_DEFAULT_DEBUG_CHANNEL(cabinet);
 
 #ifdef WORDS_BIGENDIAN
 #define fci_endian_ulong(x) RtlUlongByteSwap(x)
@@ -1024,6 +1036,7 @@ HFCI __cdecl FCICreate(
     return NULL;
   }
 
+  memset(p_fci_internal, 0, sizeof(FCI_Int));
   p_fci_internal->magic = FCI_INT_MAGIC;
   p_fci_internal->perf = perf;
   p_fci_internal->fileplaced = pfnfiledest;
@@ -1038,26 +1051,8 @@ HFCI __cdecl FCICreate(
   p_fci_internal->gettemp = pfnfcigtf;
   p_fci_internal->ccab = *pccab;
   p_fci_internal->pccab = pccab;
-  p_fci_internal->fPrevCab = FALSE;
-  p_fci_internal->fNextCab = FALSE;
-  p_fci_internal->fSplitFolder = FALSE;
-  p_fci_internal->fGetNextCabInVain = FALSE;
   p_fci_internal->pv = pv;
-  p_fci_internal->cdata_in = 0;
-  p_fci_internal->cCompressedBytesInFolder = 0;
-  p_fci_internal->cFolders = 0;
-  p_fci_internal->cFiles = 0;
-  p_fci_internal->cDataBlocks = 0;
   p_fci_internal->data.handle = -1;
-  p_fci_internal->fNewPrevious = FALSE;
-  p_fci_internal->estimatedCabinetSize = 0;
-  p_fci_internal->statusFolderTotal = 0;
-  p_fci_internal->folders_size = 0;
-  p_fci_internal->files_size = 0;
-  p_fci_internal->placed_files_size = 0;
-  p_fci_internal->pending_data_size = 0;
-  p_fci_internal->folders_data_size = 0;
-  p_fci_internal->compression = tcompTYPE_NONE;
   p_fci_internal->compress = compress_NONE;
 
   list_init( &p_fci_internal->folders_list );