summaryrefslogtreecommitdiff
path: root/util.c
diff options
context:
space:
mode:
Diffstat (limited to 'util.c')
-rw-r--r--util.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/util.c b/util.c
index aa43861067..7c83d03d70 100644
--- a/util.c
+++ b/util.c
@@ -1417,7 +1417,8 @@ Perl_mess(pTHX_ const char *pat, va_list *args)
(long)IoLINES(GvIOp(PL_last_in_gv)));
}
#ifdef USE_THREADS
- sv_catpvf(sv, " thread %ld", thr->tid);
+ if (thr->tid)
+ Perl_sv_catpvf(aTHX_ sv, " thread %ld", thr->tid);
#endif
sv_catpv(sv, PL_dirty ? dgd : ".\n");
}