summaryrefslogtreecommitdiffstats
path: root/src/global/signal_handler.cc
diff options
context:
space:
mode:
authorKefu Chai <tchaikov@gmail.com>2016-06-05 08:01:23 +0200
committerKefu Chai <tchaikov@gmail.com>2016-06-05 08:01:23 +0200
commitabe240b57ec0063fc508e9aa7e7e27b71e162fe7 (patch)
treebcfdeb2319c555f0295ae46516083f4c50da005f /src/global/signal_handler.cc
parentMerge pull request #9446 from ceph/wip-cmake (diff)
parentHeartbeatMap.cc WorkQueue.cc: fix FreeBSD pthread issues (diff)
downloadceph-abe240b57ec0063fc508e9aa7e7e27b71e162fe7.tar.xz
ceph-abe240b57ec0063fc508e9aa7e7e27b71e162fe7.zip
Merge pull request #9178 from wjwithagen/wip-wjw-freebsd-compile-2
build: freebsd changes (part 2) Reviewed-by: Kefu Chai <kchai@redhat.com>
Diffstat (limited to 'src/global/signal_handler.cc')
-rw-r--r--src/global/signal_handler.cc2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/global/signal_handler.cc b/src/global/signal_handler.cc
index 86e90e9ebca..a01a78a868a 100644
--- a/src/global/signal_handler.cc
+++ b/src/global/signal_handler.cc
@@ -90,8 +90,10 @@ static void handle_fatal_signal(int signum)
// presumably dump core-- will handle it.
char buf[1024];
char pthread_name[16] = {0}; //limited by 16B include terminating null byte.
+#if !defined(__FreeBSD__)
int r = pthread_getname_np(pthread_self(), pthread_name, sizeof(pthread_name));
(void)r;
+#endif
#if defined(__sun)
char message[SIG2STR_MAX];
sig2str(signum,message);