Fix logging percentage in BlobFileWriter.

Should clear number of stored blobs when enable logging.

Bug: 25293923
TEST=Generated a full payload, the percentage is correct.

Change-Id: Ie779d699db1b12105bbf77fbae3a02c41d28401b
diff --git a/payload_generator/full_update_generator.cc b/payload_generator/full_update_generator.cc
index f9173ef..1ae01b9 100644
--- a/payload_generator/full_update_generator.cc
+++ b/payload_generator/full_update_generator.cc
@@ -68,12 +68,6 @@
  private:
   bool ProcessChunk();
 
-  // Stores the operation blob in the |blob_fd_| and updates the
-  // |blob_file_size| accordingly.
-  // This method is thread-safe since it uses a mutex to access the file.
-  // Returns the data offset where the data was written to.
-  off_t StoreBlob(const brillo::Blob& blob);
-
   // Work parameters.
   int fd_;
   off_t offset_;
@@ -193,6 +187,10 @@
   for (ChunkProcessor& processor : chunk_processors)
     thread_pool.AddWork(&processor);
   thread_pool.JoinAll();
+
+  // All the work done, disable logging.
+  blob_file->SetTotalBlobs(0);
+
   // All the operations must have a type set at this point. Otherwise, a
   // ChunkProcessor failed to complete.
   for (const AnnotatedOperation& aop : *aops) {