Changeset 3067 for box/trunk/lib
- Timestamp:
- 22/01/2012 16:35:37 (4 months ago)
- Location:
- box/trunk/lib/backupstore
- Files:
-
- 2 edited
-
BackupClientFileAttributes.cpp (modified) (4 diffs)
-
BackupClientFileAttributes.h (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
box/trunk/lib/backupstore/BackupClientFileAttributes.cpp
r2972 r3067 124 124 // 125 125 // Function 126 // Name: BackupClientFileAttributes::BackupClientFileAttributes() 127 // Purpose: Artifical constructor 128 // Created: 2011/12/06 129 // 130 // -------------------------------------------------------------------------- 131 BackupClientFileAttributes::BackupClientFileAttributes(const EMU_STRUCT_STAT &st) 132 : mpClearAttributes(0) 133 { 134 ASSERT(sizeof(u_int64_t) == sizeof(box_time_t)); 135 StreamableMemBlock *pnewAttr = new StreamableMemBlock; 136 FillAttributes(*pnewAttr, (const char *)NULL, st, true); 137 138 // Attributes ready. Encrypt into this block 139 EncryptAttr(*pnewAttr); 140 141 // Store the new attributes 142 RemoveClear(); 143 mpClearAttributes = pnewAttr; 144 pnewAttr = 0; 145 } 146 147 // -------------------------------------------------------------------------- 148 // 149 // Function 126 150 // Name: BackupClientFileAttributes::BackupClientFileAttributes(const BackupClientFileAttributes &) 127 151 // Purpose: Copy constructor … … 437 461 // 438 462 // Function 439 // Name: BackupClientFileAttributes:: ReadAttributesLink()463 // Name: BackupClientFileAttributes::FillAttributes() 440 464 // Purpose: Private function, handles standard attributes for all objects 441 465 // Created: 2003/10/07 442 466 // 443 467 // -------------------------------------------------------------------------- 444 void BackupClientFileAttributes::FillAttributes(StreamableMemBlock &outputBlock, const char *Filename, EMU_STRUCT_STAT &st, bool ZeroModificationTimes) 468 void BackupClientFileAttributes::FillAttributes( 469 StreamableMemBlock &outputBlock, const char *Filename, 470 const EMU_STRUCT_STAT &st, bool ZeroModificationTimes 471 ) 445 472 { 446 473 outputBlock.ResizeBlock(sizeof(attr_StreamFormat)); … … 476 503 // 477 504 // Function 478 // Name: BackupClientFileAttributes::ReadAttributesLink() 505 // Name: BackupClientFileAttributes::FillAttributesLink( 506 // StreamableMemBlock &outputBlock, 507 // const char *Filename, struct stat &st) 479 508 // Purpose: Private function, handles the case where a symbolic link is needed 480 509 // Created: 2003/10/07 … … 508 537 // 509 538 // Function 510 // Name: BackupClientFileAttributes:: ReadExtendedAttr(const char *, unsigned char**)539 // Name: BackupClientFileAttributes::FillExtendedAttr(const char *, unsigned char**) 511 540 // Purpose: Private function, read the extended attributes of the file into the block 512 541 // Created: 2005/06/12 -
box/trunk/lib/backupstore/BackupClientFileAttributes.h
r2945 r3067 30 30 public: 31 31 BackupClientFileAttributes(); 32 BackupClientFileAttributes(const EMU_STRUCT_STAT &st); 32 33 BackupClientFileAttributes(const BackupClientFileAttributes &rToCopy); 33 34 BackupClientFileAttributes(const StreamableMemBlock &rToCopy); … … 61 62 private: 62 63 static void FillAttributes(StreamableMemBlock &outputBlock, 63 const char *Filename, EMU_STRUCT_STAT &st,64 const char *Filename, const EMU_STRUCT_STAT &st, 64 65 bool ZeroModificationTimes); 65 66 static void FillAttributesLink(StreamableMemBlock &outputBlock, const char *Filename, struct stat &st);
Note: See TracChangeset
for help on using the changeset viewer.
