diff options
Diffstat (limited to 'lib/libpthread/thread/thr_gc.c')
| -rw-r--r-- | lib/libpthread/thread/thr_gc.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/libpthread/thread/thr_gc.c b/lib/libpthread/thread/thr_gc.c index a6ffd4ba58d7..cd1f8383a33d 100644 --- a/lib/libpthread/thread/thr_gc.c +++ b/lib/libpthread/thread/thr_gc.c @@ -242,6 +242,10 @@ _thread_gc(pthread_addr_t arg) if (p_stack != NULL) free(p_stack); if (pthread_cln != NULL) + if (pthread_cln->name != NULL) { + /* Free the thread name string. */ + free(pthread_cln->name); + } /* * Free the memory allocated for the thread * structure. |
