Skip to content

Commit ba1a1db

Browse files
committed
locale.c: debug with thread id
1 parent b8b2ef3 commit ba1a1db

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

locale.c

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -118,6 +118,7 @@
118118
* initialization. This is done before option parsing, and before any thread
119119
* creation, so can be a file-level static. (Must come before #including
120120
* perl.h) */
121+
#include "config.h"
121122
#ifdef DEBUGGING
122123
static int debug_initialization = 0;
123124
# define DEBUG_INITIALIZATION_set(v) (debug_initialization = v)
@@ -127,9 +128,9 @@ static int debug_initialization = 0;
127128
* (or their corresponding unsigned type). So, we have to explicitly cast
128129
* __LINE__ to a particular integer type to pass it reliably to variadic
129130
* functions like (PerlIO_)printf, as below: */
130-
# ifdef USE_LOCALE_THREADS
131+
# if defined(USE_ITHREADS) && ! defined(NO_LOCALE_THREADS)
131132
# define DEBUG_PRE_STMTS \
132-
dSAVE_ERRNO; dTHX; PerlIO_printf(Perl_debug_log,"\n%s: %" LINE_Tf ": %p: ",\
133+
dSAVE_ERRNO; dTHX; PerlIO_printf(Perl_debug_log,"\n%s: %" LINE_Tf ": 0x%p: ",\
133134
__FILE__, (line_t)__LINE__, aTHX);
134135
# else
135136
# define DEBUG_PRE_STMTS \

0 commit comments

Comments
 (0)