Re: [PATCH 02/11] repository: introduce repo_read_index_or_die

2018-05-22 Thread Duy Nguyen
On Mon, May 21, 2018 at 9:27 PM, Stefan Beller wrote: > Hi Brandon, > >>> One of the reviewers of the series questioned the overall goal of the >>> series as we want to move away from _die() in top level code but this >>> series moves more towards it. >> >> I've heard every

Re: [PATCH 02/11] repository: introduce repo_read_index_or_die

2018-05-21 Thread Stefan Beller
Hi Brandon, >> One of the reviewers of the series questioned the overall goal of the >> series as we want to move away from _die() in top level code but this >> series moves more towards it. > > I've heard every once in a while that we want to move toward this but I > don't believe there is an

Re: [PATCH 02/11] repository: introduce repo_read_index_or_die

2018-05-21 Thread Brandon Williams
On 05/21, Stefan Beller wrote: > On Fri, May 18, 2018 at 11:37 PM, Duy Nguyen wrote: > > On Wed, May 16, 2018 at 03:21:09PM -0700, Stefan Beller wrote: > >> A common pattern with the repo_read_index function is to die if the return > >> of repo_read_index is negative. Move

Re: [PATCH 02/11] repository: introduce repo_read_index_or_die

2018-05-21 Thread Stefan Beller
On Fri, May 18, 2018 at 11:37 PM, Duy Nguyen wrote: > On Wed, May 16, 2018 at 03:21:09PM -0700, Stefan Beller wrote: >> A common pattern with the repo_read_index function is to die if the return >> of repo_read_index is negative. Move this pattern into a function. >> >> This

Re: [PATCH 02/11] repository: introduce repo_read_index_or_die

2018-05-19 Thread Duy Nguyen
On Wed, May 16, 2018 at 03:21:09PM -0700, Stefan Beller wrote: > A common pattern with the repo_read_index function is to die if the return > of repo_read_index is negative. Move this pattern into a function. > > This patch replaces the calls of repo_read_index with its _or_die version, > if the

[PATCH 02/11] repository: introduce repo_read_index_or_die

2018-05-16 Thread Stefan Beller
A common pattern with the repo_read_index function is to die if the return of repo_read_index is negative. Move this pattern into a function. This patch replaces the calls of repo_read_index with its _or_die version, if the error message is exactly the same. Signed-off-by: Stefan Beller