xref: /haiku/src/system/kernel/util/KernelReferenceable.cpp (revision 1e60bdeab63fa7a57bc9a55b032052e95a18bd2c)
1 /*
2  * Copyright 2011, Ingo Weinhold, ingo_weinhold@gmx.de.
3  * Distributed under the terms of the MIT License.
4  */
5 
6 
7 #include <util/KernelReferenceable.h>
8 
9 #include <int.h>
10 
11 
12 void
13 KernelReferenceable::LastReferenceReleased()
14 {
15 	if (are_interrupts_enabled())
16 		delete this;
17 	else
18 		deferred_delete(this);
19 }
20