From f4609b896fac842433bd495c166d5987852a6a73 Mon Sep 17 00:00:00 2001 From: Vincent Ambo Date: Sat, 21 Nov 2020 19:20:35 +0100 Subject: merge(3p/git): Merge git subtree at v2.29.2 This also bumps the stable nixpkgs to 20.09 as of 2020-11-21, because there is some breakage in the git build related to the netrc credentials helper which someone has taken care of in nixpkgs. The stable channel is not used for anything other than git, so this should be fine. Change-Id: I3575a19dab09e1e9556cf8231d717de9890484fb --- third_party/git/builtin/upload-archive.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'third_party/git/builtin/upload-archive.c') diff --git a/third_party/git/builtin/upload-archive.c b/third_party/git/builtin/upload-archive.c index 018879737a..24654b4c9b 100644 --- a/third_party/git/builtin/upload-archive.c +++ b/third_party/git/builtin/upload-archive.c @@ -7,7 +7,7 @@ #include "pkt-line.h" #include "sideband.h" #include "run-command.h" -#include "argv-array.h" +#include "strvec.h" static const char upload_archive_usage[] = "git upload-archive "; @@ -19,7 +19,7 @@ static const char deadchild[] = int cmd_upload_archive_writer(int argc, const char **argv, const char *prefix) { - struct argv_array sent_argv = ARGV_ARRAY_INIT; + struct strvec sent_argv = STRVEC_INIT; const char *arg_cmd = "argument "; if (argc != 2 || !strcmp(argv[1], "-h")) @@ -31,21 +31,21 @@ int cmd_upload_archive_writer(int argc, const char **argv, const char *prefix) init_archivers(); /* put received options in sent_argv[] */ - argv_array_push(&sent_argv, "git-upload-archive"); + strvec_push(&sent_argv, "git-upload-archive"); for (;;) { char *buf = packet_read_line(0, NULL); if (!buf) break; /* got a flush */ - if (sent_argv.argc > MAX_ARGS) + if (sent_argv.nr > MAX_ARGS) die("Too many options (>%d)", MAX_ARGS - 1); if (!starts_with(buf, arg_cmd)) die("'argument' token or flush expected"); - argv_array_push(&sent_argv, buf + strlen(arg_cmd)); + strvec_push(&sent_argv, buf + strlen(arg_cmd)); } /* parse all options sent by the client */ - return write_archive(sent_argv.argc, sent_argv.argv, prefix, + return write_archive(sent_argv.nr, sent_argv.v, prefix, the_repository, NULL, 1); } -- cgit 1.4.1