> Jonathan Tan <jonathantanmy@xxxxxxxxxx> writes: > > > In send_fetch_request(), "object-format" is written directly to the file > > descriptor, as opposed to the other arguments, which are buffered. > > Buffer "object-format" as well. "object-format" must be buffered; in > > particular, it must appear after "command=fetch" in the request. > > > > This divergence was introduced in 4b831208bb ("fetch-pack: parse and > > advertise the object-format capability", 2020-05-27), perhaps as an > > oversight (the surrounding code at the point of this commit has already > > been using a request buffer.) > > Good find. Did this actually resulted in a data corruption and that > was how you discovered it? No, I did not see any data corruption. I discovered it because I was looking at this function, thinking that I needed to refactor it.