Skip to content

Commit

Permalink
Merge branch 'vd/pthread-setspecific-g11-fix' into next
Browse files Browse the repository at this point in the history
* vd/pthread-setspecific-g11-fix:
  async_die_is_recursing: work around GCC v11.x issue on Fedora
  • Loading branch information
gitster committed Nov 4, 2021
2 parents 1ee6274 + 4b540cf commit b4fce69
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion run-command.c
Original file line number Diff line number Diff line change
Expand Up @@ -1099,7 +1099,7 @@ static NORETURN void die_async(const char *err, va_list params)
static int async_die_is_recursing(void)
{
void *ret = pthread_getspecific(async_die_counter);
pthread_setspecific(async_die_counter, (void *)1);
pthread_setspecific(async_die_counter, &async_die_counter); /* set to any non-NULL valid pointer */
return ret != NULL;
}

Expand Down

0 comments on commit b4fce69

Please sign in to comment.