bionic/libstdc++/src/pure_virtual.cpp
Elliott Hughes 8f2a5a0b40 Clean up internal libc logging.
We only need one logging API, and I prefer the one that does no
allocation and is thus safe to use in any context.

Also use O_CLOEXEC when opening the /dev/log files.

Move everything logging-related into one header file.

Change-Id: Ic1e3ea8e9b910dc29df351bff6c0aa4db26fbb58
2013-03-15 16:12:58 -07:00

9 lines
285 B
C++

#undef NDEBUG
#include <assert.h>
extern "C" void __cxa_pure_virtual() {
// We can't call __libc_format_log from libstdc++ because it's hidden and in libc, so cheat.
assert(!"Pure virtual function called. Are you calling virtual methods from a destructor?");
/* NOTREACHED */
}