From 134509a8ea96e54122b50bba20b5baef9597cc3a Mon Sep 17 00:00:00 2001 From: Andrew Johnson Date: Wed, 8 Apr 2009 22:39:27 +0000 Subject: [PATCH] Thread name may not be available during termination. --- src/libCom/test/epicsExitTest.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/libCom/test/epicsExitTest.c b/src/libCom/test/epicsExitTest.c index 2280693fb..f464b707c 100644 --- a/src/libCom/test/epicsExitTest.c +++ b/src/libCom/test/epicsExitTest.c @@ -26,7 +26,7 @@ typedef struct info { - const char *name; + char name[64]; epicsEventId terminate; epicsEventId terminated; }info; @@ -55,7 +55,7 @@ static void thread(void *arg) { info *pinfo = (info *)arg; - pinfo->name = epicsThreadGetNameSelf(); + strcpy(pinfo->name, epicsThreadGetNameSelf()); testDiag("%s starting", pinfo->name); pinfo->terminate = epicsEventMustCreate(epicsEventEmpty); pinfo->terminated = epicsEventMustCreate(epicsEventEmpty);