summaryrefslogtreecommitdiffstats
path: root/bgpd/bgp_keepalives.c
diff options
context:
space:
mode:
authorChirag Shah <chirag@cumulusnetworks.com>2018-07-30 17:05:42 +0200
committerChirag Shah <chirag@cumulusnetworks.com>2018-08-30 00:41:54 +0200
commit57019528a0279c3a6b2caa2100f5c6199ad378f2 (patch)
treef36321071410a60a4df64d33bd19039421408f09 /bgpd/bgp_keepalives.c
parentMerge pull request #2938 from pguibert6WIND/spurious_message (diff)
downloadfrr-57019528a0279c3a6b2caa2100f5c6199ad378f2.tar.xz
frr-57019528a0279c3a6b2caa2100f5c6199ad378f2.zip
*: pthread set name abstraction
Testing Done: TOR#cat /proc/2670/task/2672/comm bgpd_ka TOR# ps H -C bgpd -o 'pid tid cmd comm' PID TID CMD COMMAND 2670 2670 /usr/lib/frr/bgpd -M snmp - bgpd 2670 2671 /usr/lib/frr/bgpd -M snmp - bgpd 2670 2672 /usr/lib/frr/bgpd -M snmp - bgpd_ka Signed-off-by: Chirag Shah <chirag@cumulusnetworks.com>
Diffstat (limited to 'bgpd/bgp_keepalives.c')
-rw-r--r--bgpd/bgp_keepalives.c6
1 files changed, 1 insertions, 5 deletions
diff --git a/bgpd/bgp_keepalives.c b/bgpd/bgp_keepalives.c
index f81836cc8..aeb95f91b 100644
--- a/bgpd/bgp_keepalives.c
+++ b/bgpd/bgp_keepalives.c
@@ -180,11 +180,7 @@ void *bgp_keepalives_start(void *arg)
pthread_cond_init(peerhash_cond, &attrs);
pthread_condattr_destroy(&attrs);
-#ifdef GNU_LINUX
- pthread_setname_np(fpt->thread, "bgpd_ka");
-#elif defined(OPEN_BSD)
- pthread_set_name_np(fpt->thread, "bgpd_ka");
-#endif
+ frr_pthread_set_name(fpt, NULL, "bgpd_ka");
/* initialize peer hashtable */
peerhash = hash_create_size(2048, peer_hash_key, peer_hash_cmp, NULL);