From: Junio C Hamano Date: Tue, 10 Apr 2018 03:21:19 GMT Subject: Re: [PATCH 05/16] replace-object: eliminate replace objects prepared flag Message-ID: In-Reply-To: <20180409224533.17764-6-sbeller@google.com> Stefan Beller writes: > By making the oidmap a pointer, we eliminate the need for > the global boolean variable 'replace_object_prepared'. That is not quite a justification for this change, as making it a pointer (and paying for the malloc(3) overhead) is not the only way to remove the variable (i.e. the "has this been initialized?" bit can be moved to "struct raw_object_store"). One possible advantage of this approach, I guess, is that we would more quickly catch code that tries to access replace-map without initializing it.