Changeset 3068


Ignore:
Timestamp:
22/01/2012 16:36:27 (4 months ago)
Author:
chris
Message:

Rename the BackupStoreDirectory::AddEntry?'s AttributesModTime? parameter to AttributesHash? to avoid misleading the reader.

Location:
box/trunk/lib/backupstore
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • box/trunk/lib/backupstore/BackupStoreDirectory.cpp

    r2945 r3068  
    116116// Function 
    117117//              Name:    BackupStoreDirectory::ReadFromStream(IOStream &, int) 
    118 //              Purpose: Reads the directory contents from a stream. Exceptions will yeild incomplete reads. 
     118//              Purpose: Reads the directory contents from a stream. 
     119//                       Exceptions will result in incomplete reads. 
    119120//              Created: 2003/08/26 
    120121// 
     
    132133        if(OBJECTMAGIC_DIR_MAGIC_VALUE != ntohl(hdr.mMagicValue)) 
    133134        { 
    134                 THROW_EXCEPTION(BackupStoreException, BadDirectoryFormat) 
     135                THROW_EXCEPTION_MESSAGE(BackupStoreException, BadDirectoryFormat, 
     136                        "Wrong magic number in directory object " <<  
     137                        BOX_FORMAT_OBJECTID(mObjectID) << ": expected " << 
     138                        BOX_FORMAT_HEX32(OBJECTMAGIC_DIR_MAGIC_VALUE) << 
     139                        " but found " << 
     140                        BOX_FORMAT_HEX32(ntohl(hdr.mMagicValue))); 
    135141        } 
    136142         
     
    308314// 
    309315// -------------------------------------------------------------------------- 
    310 BackupStoreDirectory::Entry *BackupStoreDirectory::AddEntry(const BackupStoreFilename &rName, box_time_t ModificationTime, int64_t ObjectID, int64_t SizeInBlocks, int16_t Flags, box_time_t AttributesModTime) 
    311 { 
    312         Entry *pnew = new Entry(rName, ModificationTime, ObjectID, SizeInBlocks, Flags, AttributesModTime); 
     316BackupStoreDirectory::Entry * 
     317BackupStoreDirectory::AddEntry(const BackupStoreFilename &rName, 
     318        box_time_t ModificationTime, int64_t ObjectID, int64_t SizeInBlocks, 
     319        int16_t Flags, uint64_t AttributesHash) 
     320{ 
     321        Entry *pnew = new Entry(rName, ModificationTime, ObjectID, 
     322                SizeInBlocks, Flags, AttributesHash); 
    313323        try 
    314324        { 
  • box/trunk/lib/backupstore/BackupStoreDirectory.h

    r3038 r3068  
    150150                         
    151151        Entry *AddEntry(const Entry &rEntryToCopy); 
    152         Entry *AddEntry(const BackupStoreFilename &rName, box_time_t ModificationTime, int64_t ObjectID, int64_t SizeInBlocks, int16_t Flags, box_time_t AttributesModTime); 
     152        Entry *AddEntry(const BackupStoreFilename &rName, 
     153                box_time_t ModificationTime, int64_t ObjectID, 
     154                int64_t SizeInBlocks, int16_t Flags, 
     155                uint64_t AttributesHash); 
    153156        void DeleteEntry(int64_t ObjectID); 
    154157        Entry *FindEntryByID(int64_t ObjectID) const; 
Note: See TracChangeset for help on using the changeset viewer.