From: Junio C Hamano Date: Thu, 14 Jun 2018 19:36:19 GMT Subject: Re: [PATCH v2 5/8] fetch-pack: make negotiation-related vars local Message-ID: In-Reply-To: <955d9f62d2c8400791501d71c72fea4ef2dc1cff.1528317619.git.jonathantanmy@google.com> Jonathan Tan writes: > -static struct prio_queue rev_list = { compare_commits_by_commit_date }; > -static int non_common_revs, multi_ack, use_sideband; > +struct data { > + struct prio_queue rev_list; > + int non_common_revs; > +}; > + > +static int multi_ack, use_sideband; Aside from Brandon's comments, I think passing these throughout the callchain instead of having them as static-globals is a step in the right direction. Could you, however, give the structure a bit more descriptive name, than simply "data"? Anything the computer works on is "data", and there must be something more specific than that about this particular struct ;-)