summaryrefslogtreecommitdiffstats
path: root/src/common/assert.cc
diff options
context:
space:
mode:
authorYehuda Sadeh <yehuda@hq.newdream.net>2009-02-10 01:29:43 +0100
committerYehuda Sadeh <yehuda@hq.newdream.net>2009-02-10 01:29:43 +0100
commitb1203c227e8f247f763b2e26347048a4a9cda8c2 (patch)
tree54ec471494270a63486893da01636a8595885f81 /src/common/assert.cc
parentadded a common initialization function (diff)
downloadceph-b1203c227e8f247f763b2e26347048a4a9cda8c2.tar.xz
ceph-b1203c227e8f247f763b2e26347048a4a9cda8c2.zip
assert: warn on assertion if requested for current thread
Diffstat (limited to 'src/common/assert.cc')
-rw-r--r--src/common/assert.cc5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/common/assert.cc b/src/common/assert.cc
index 03340acad4b..909d791c5fe 100644
--- a/src/common/assert.cc
+++ b/src/common/assert.cc
@@ -28,3 +28,8 @@ void __ceph_assert_fail(const char *assertion, const char *file, int line, const
while (1)
*p-- = 0; // make myself core dump.
}
+
+void __ceph_assert_warn(const char *assertion, const char *file, int line, const char *func)
+{
+ *_dout << "WARNING: assert(" << assertion << ") at: " << file << ":" << line << ": " << func << "()" << std::endl;
+}