Re: [PATCH] submodule: use cheaper check for submodule pushes

2017-07-13 Thread Stefan Beller
On Thu, Jul 13, 2017 at 1:48 PM, Jonathan Nieder wrote: > Hi, > > Stefan Beller wrote: > >> Yes we are safe, because the function itself only spawns a child process >> (not using any of the objects). >> >> It's only caller push_unpushed_submodules also doesn't rely on objects >> loaded after calli

Re: [PATCH] submodule: use cheaper check for submodule pushes

2017-07-13 Thread Jonathan Nieder
Hi, Stefan Beller wrote: > Yes we are safe, because the function itself only spawns a child process > (not using any of the objects). > > It's only caller push_unpushed_submodules also doesn't rely on objects > loaded after calling push_submodule. > > The caller of push_unpushed_submodules (trans

Re: [PATCH] submodule: use cheaper check for submodule pushes

2017-07-13 Thread Stefan Beller
On Thu, Jul 13, 2017 at 11:37 AM, Junio C Hamano wrote: > > I think Jonathan's question (which I concurred) is if we also ended > up relying on the side effect of calling that function (i.e. being > able to now find objects that are not in our repository but in the > submodule's object store). B

Re: [PATCH] submodule: use cheaper check for submodule pushes

2017-07-13 Thread Junio C Hamano
Stefan Beller writes: > On Wed, Jul 12, 2017 at 5:53 PM, Junio C Hamano wrote: >> Jonathan Nieder writes: >> In the function push_submodule[1] we use add_submodule_odb[2] to determine if a submodule has been populated. However the function does not work with the submodules object

Re: [PATCH] submodule: use cheaper check for submodule pushes

2017-07-12 Thread Stefan Beller
On Wed, Jul 12, 2017 at 5:53 PM, Junio C Hamano wrote: > Jonathan Nieder writes: > >>> In the function push_submodule[1] we use add_submodule_odb[2] to determine >>> if a submodule has been populated. However the function does not work with >>> the submodules objects that are added, instead a new

Re: [PATCH] submodule: use cheaper check for submodule pushes

2017-07-12 Thread Junio C Hamano
Jonathan Nieder writes: >> In the function push_submodule[1] we use add_submodule_odb[2] to determine >> if a submodule has been populated. However the function does not work with >> the submodules objects that are added, instead a new child process is used >> to perform the actual push in the su

Re: [PATCH] submodule: use cheaper check for submodule pushes

2017-07-12 Thread Stefan Beller
On Wed, Jul 12, 2017 at 5:01 PM, Jonathan Nieder wrote: > These footnotes don't answer the question that I really have: why did > this use add_submodule_odb in the first place? oh, I forgot to put that down: presumably add_submodule_odb was used because it was available back then? Note the dates

Re: [PATCH] submodule: use cheaper check for submodule pushes

2017-07-12 Thread Jonathan Nieder
Hi, Stefan Beller wrote: > In the function push_submodule[1] we use add_submodule_odb[2] to determine > if a submodule has been populated. However the function does not work with > the submodules objects that are added, instead a new child process is used > to perform the actual push in the submo

[PATCH] submodule: use cheaper check for submodule pushes

2017-07-12 Thread Stefan Beller
In the function push_submodule[1] we use add_submodule_odb[2] to determine if a submodule has been populated. However the function does not work with the submodules objects that are added, instead a new child process is used to perform the actual push in the submodule. Use is_submodule_populated[3