cabinet: Assign to structs instead of using memcpy

Andrew Talbot andrew.talbot at talbotville.com
Mon Feb 11 14:48:58 CST 2008


Changelog:
    cabinet: Assign to structs instead of using memcpy.

diff --git a/dlls/cabinet/fci.c b/dlls/cabinet/fci.c
index a33f2e3..ea745a6 100644
--- a/dlls/cabinet/fci.c
+++ b/dlls/cabinet/fci.c
@@ -1331,7 +1331,7 @@ static BOOL fci_flush_folder(
       )
   ) {
     /* save CCAB */
-    memcpy(&(p_fci_internal->oldCCAB), p_fci_internal->pccab, sizeof(CCAB));
+    p_fci_internal->oldCCAB = *p_fci_internal->pccab;
     /* increment cabinet index */
     ++(p_fci_internal->pccab->iCab);
     /* get name of next cabinet */
@@ -2244,7 +2244,7 @@ static BOOL fci_flush_cabinet(
       CB_MAX_CABINET_NAME + CB_MAX_DISK_NAME
     )) {
       /* save CCAB */
-      memcpy(&(p_fci_internal->oldCCAB), p_fci_internal->pccab, sizeof(CCAB));
+      p_fci_internal->oldCCAB = *p_fci_internal->pccab;
       /* increment cabinet index */
       ++(p_fci_internal->pccab->iCab);
       /* get name of next cabinet */
@@ -2477,7 +2477,7 @@ BOOL __cdecl FCIAddFile(
       )
   ) {
     /* save CCAB */
-    memcpy(&(p_fci_internal->oldCCAB), p_fci_internal->pccab, sizeof(CCAB));
+    p_fci_internal->oldCCAB = *p_fci_internal->pccab;
     /* increment cabinet index */
     ++(p_fci_internal->pccab->iCab);
     /* get name of next cabinet */
@@ -2644,7 +2644,7 @@ BOOL __cdecl FCIAddFile(
       )
   ) {
     /* save CCAB */
-    memcpy(&(p_fci_internal->oldCCAB), p_fci_internal->pccab, sizeof(CCAB));
+    p_fci_internal->oldCCAB = *p_fci_internal->pccab;
     /* increment cabinet index */
     ++(p_fci_internal->pccab->iCab);
     /* get name of next cabinet */



More information about the wine-patches mailing list