mirror of
https://github.com/git-for-windows/git.git
synced 2026-04-10 08:22:54 -05:00
mingw: allow for longer paths in parse_interpreter()
As reported in https://github.com/newren/git-filter-repo/pull/225, it looks like 99 bytes is not really sufficient to represent e.g. the full path to Python when installed via Windows Store (and this path is used in the hasb bang line when installing scripts via `pip`). Let's increase it to what is probably the maximum sensible path size: MAX_PATH. This makes `parse_interpreter()` in line with what `lookup_prog()` handles. Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> Signed-off-by: Vilius Šumskas <vilius@sumskas.eu>
This commit is contained in:
committed by
Git for Windows Build Agent
parent
449904e090
commit
6351c5715f
@@ -1605,7 +1605,7 @@ static const char *quote_arg_msys2(const char *arg)
|
||||
|
||||
static const char *parse_interpreter(const char *cmd)
|
||||
{
|
||||
static char buf[100];
|
||||
static char buf[MAX_PATH];
|
||||
char *p, *opt;
|
||||
ssize_t n; /* read() can return negative values */
|
||||
int fd;
|
||||
|
||||
Reference in New Issue
Block a user