Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(287)

Unified Diff: import/cross/tar_generator.h

Issue 159129: Refactor tar code to support long names.... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/o3d/
Patch Set: Created 11 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | import/cross/tar_generator.cc » ('j') | import/cross/tar_generator.cc » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: import/cross/tar_generator.h
===================================================================
--- import/cross/tar_generator.h (revision 21085)
+++ import/cross/tar_generator.h (working copy)
@@ -67,7 +67,7 @@
// Call AddFile() for each file entry, followed by calls to AddFileBytes()
// for the file's data
- virtual void AddFile(const String &file_name,
+ virtual bool AddFile(const String &file_name,
Chris Rogers 2009/07/21 19:14:28 add comment about return value
size_t file_size);
// Call to "push" bytes to be processed - our client will get called back
@@ -79,16 +79,25 @@
virtual void Finalize();
private:
- void AddEntry(const String &file_name,
+ bool AddEntry(const String &file_name,
Chris Rogers 2009/07/21 19:14:28 add comment about return value
size_t file_size,
bool is_directory);
- void AddDirectory(const String &file_name);
- void AddDirectoryEntryIfNeeded(const String &file_name);
+ bool AddDirectory(const String &file_name);
Chris Rogers 2009/07/21 19:14:28 comment about return value
+ bool AddDirectoryEntryIfNeeded(const String &file_name);
// Checksum for each header
void ComputeCheckSum(uint8 *header);
+ // Writes a head block.
+ void WriteHeader(const String& filename,
+ size_t file_size,
+ char type,
+ int mode,
+ int user_id,
+ int group_id,
+ int mod_time);
+
// flushes buffered file data to the client callback
// if |flush_padding_zeroes| is |true| then flush a complete block
// with zero padding even if less was buffered
« no previous file with comments | « no previous file | import/cross/tar_generator.cc » ('j') | import/cross/tar_generator.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698