Initialize the BKey to default values and set fCreationTime.
* Using Unset() initializes the BKey to default values. * Also set fCreationTime to 0 for now. It is still unused but needs to have a stable value for the exact matches when comparing keys.
This commit is contained in:
committed by
Ryan Leavengood
parent
b31a707a95
commit
f17ddab827
@@ -32,6 +32,7 @@ CompareLists(BObjectList<BString> a, BObjectList<BString> b)
|
||||
|
||||
BKey::BKey()
|
||||
{
|
||||
Unset();
|
||||
}
|
||||
|
||||
|
||||
@@ -44,6 +45,7 @@ BKey::BKey(BKeyPurpose purpose, const char* identifier,
|
||||
|
||||
BKey::BKey(BKey& other)
|
||||
{
|
||||
*this = other;
|
||||
}
|
||||
|
||||
|
||||
@@ -63,6 +65,7 @@ status_t
|
||||
BKey::SetTo(BKeyPurpose purpose, const char* identifier,
|
||||
const char* secondaryIdentifier, const uint8* data, size_t length)
|
||||
{
|
||||
fCreationTime = 0;
|
||||
SetPurpose(purpose);
|
||||
SetIdentifier(identifier);
|
||||
SetSecondaryIdentifier(secondaryIdentifier);
|
||||
|
||||
Reference in New Issue
Block a user