[ostree/wip/delta2] delta: Fix location of uncompressed size calculation



commit b9d74c5259fa2ac10a52182cf1e260a7dbaea606
Author: Colin Walters <walters verbum org>
Date:   Sat Apr 19 17:45:55 2014 -0400

    delta: Fix location of uncompressed size calculation

 .../ostree-repo-static-delta-compilation.c         |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/src/libostree/ostree-repo-static-delta-compilation.c 
b/src/libostree/ostree-repo-static-delta-compilation.c
index 722b9bb..58a75b1 100644
--- a/src/libostree/ostree-repo-static-delta-compilation.c
+++ b/src/libostree/ostree-repo-static-delta-compilation.c
@@ -170,8 +170,6 @@ generate_delta_lowlatency (OstreeRepo                       *repo,
                                            cancellable, error))
         goto out;
 
-      current_part->uncompressed_size += content_size;
-
       /* Ensure we have at least one object per delta, even if a given
        * object is larger.
        */
@@ -181,6 +179,8 @@ generate_delta_lowlatency (OstreeRepo                       *repo,
           current_part = allocate_part (builder);
         } 
 
+      current_part->uncompressed_size += content_size;
+
       g_ptr_array_add (current_part->objects, g_variant_ref (serialized_key));
 
       object_payload_start = current_part->payload->len;


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]