WeakReferenceable: Allow reference counts of either 0 or 1 during destruction.
Same rationale as for BReferenceable. Fixes a KDL seen on boot by at least one user following prior changes.
This commit is contained in:
parent
6f7201128c
commit
b956691cdd
@ -79,7 +79,7 @@ BWeakReferenceable::BWeakReferenceable()
|
||||
|
||||
BWeakReferenceable::~BWeakReferenceable()
|
||||
{
|
||||
if (fPointer->UseCount() > 0) {
|
||||
if (fPointer->UseCount() != 0 && fPointer->UseCount() != 1) {
|
||||
char message[256];
|
||||
snprintf(message, sizeof(message), "deleting referenceable object %p with "
|
||||
"reference count (%" B_PRId32 ")", this, fPointer->UseCount());
|
||||
|
Loading…
Reference in New Issue
Block a user