mirror of
https://github.com/git-for-windows/git.git
synced 2026-04-04 18:24:09 -05:00
Recently some GitHub CI jobs were broken by update on the platform side, which was eventually resolved by image rollback, but in the meantime Dscho invented a workaround patch to sidestep the broken part of the platform. Their future image update may contain the same bug, in which case the workaround may again become needed. As we do not want to be building with workaround that avoids system regexp library altogether unless the system is known to be broken, so short of an automated "detect broken system and apply workaround" mechanism, let's use the folks who are compiling the code to detect breakage on their system and cope with the breakage ;-) Signed-off-by: Junio C Hamano <gitster@pobox.com>
15 lines
388 B
C
15 lines
388 B
C
#include "../git-compat-util.h"
|
|
#undef regcomp
|
|
|
|
int git_regcomp(regex_t *preg, const char *pattern, int cflags)
|
|
{
|
|
/*
|
|
* If you are on macOS with clang and fail to compile this line,
|
|
* https://lore.kernel.org/git/458ad3c1-96df-4575-ee42-e6eb754f25f6@gmx.de/
|
|
* might be relevant.
|
|
*/
|
|
if (!(cflags & REG_EXTENDED))
|
|
cflags |= REG_ENHANCED;
|
|
return regcomp(preg, pattern, cflags);
|
|
}
|