Re: [PATCH v2 2/4] run-command: use BUG() to report bugs, not die()

2018-05-07 Thread Jeff King
On Wed, May 02, 2018 at 11:38:31AM +0200, Johannes Schindelin wrote: > The slightly misleading name die_bug() of the function intended to > report a bug is actually called always, and only reports a bug if the > passed-in parameter `err` is non-zero. > > It uses die_errno() to report the bug, to

[PATCH v2 2/4] run-command: use BUG() to report bugs, not die()

2018-05-02 Thread Johannes Schindelin
The slightly misleading name die_bug() of the function intended to report a bug is actually called always, and only reports a bug if the passed-in parameter `err` is non-zero. It uses die_errno() to report the bug, to helpfully include the error message corresponding to `err`. However, as these