if loglevel > 999, log thread id as part of logging
#include "host.h"
#ifdef AFS_PTHREAD_ENV
#include "softsig.h"
+char *(*threadNameProgram) ();
#endif
#if defined(AFS_SGI_ENV)
#include "sys/schedctl.h"
#endif
}
+#if defined(AFS_PTHREAD_ENV)
+char *
+threadName(void)
+{
+ char threadid[16];
+ if (LogLevel > 999) {
+ afs_snprintf(threadid, 16, "%d", pthread_getspecific(rx_thread_id_key));
+ return threadid;
+ } else
+ return NULL;
+}
+#endif
/* proc called by rxkad module to get a key */
static int
V_BreakVolumeCallbacks = BreakVolumeCallBacksLater;
}
+#if defined(AFS_PTHREAD_ENV)
+ threadNameProgram = threadName;
+#endif
+
/* initialize libacl routines */
acl_Initialize(ACL_VERSION);