Skip to content

Commit a73934c

Browse files
committed
Merge branch 'vd/pthread-setspecific-g11-fix'
One CI task based on Fedora image noticed a not-quite-kosher consturct recently, which has been corrected. * vd/pthread-setspecific-g11-fix: async_die_is_recursing: work around GCC v11.x issue on Fedora
2 parents ada03fc + 4b540cf commit a73934c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

run-command.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1099,7 +1099,7 @@ static NORETURN void die_async(const char *err, va_list params)
10991099
static int async_die_is_recursing(void)
11001100
{
11011101
void *ret = pthread_getspecific(async_die_counter);
1102-
pthread_setspecific(async_die_counter, (void *)1);
1102+
pthread_setspecific(async_die_counter, &async_die_counter); /* set to any non-NULL valid pointer */
11031103
return ret != NULL;
11041104
}
11051105

0 commit comments

Comments
 (0)