git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH] Use exit 1 instead of die when req_Root fails.

From
Brian Gernhardt <benji@silverinsanity.com>
Date
Oct 17, 2007, 18:40 UTC
Message-ID
<8B2F7666-DCEB-4D58-ACFE-F40587CD415D@silverinsanity.com>
In-Reply-To
<8c5c35580710170839l4b31a4fao5b41efafc5a83883@mail.gmail.com>

I wish I got this much attention the first time I tried to get this problem fixed. ;-)

On Oct 17, 2007, at 11:39 AM, Lars Hjemli wrote:
> This makes me wonder: what about all the other instances of die() in
> git-cvsserver? Or in any of the other perl scripts, for that matter?
> Should they all be fixed, or is it this particular test that is wrong?

The reason this comes up is because t/test-lib.sh:test_expect_failure () thinks codes > 128 (or negative values if you want to look at it that way) are bad tests. I believe this is because many shells use these codes to indicate things like "command not found" or other probably unexpected failures.

Other than that, does it matter what die() returns, as long as it's non-zero?

~~Brian
Previous: Lars HjemliNext: Lars Hjemli
Message 5 of 12 in “Use exit 1 instead of die when req_Root fails.”
  1. Use exit 1 instead of die when req_Root fails.Brian Gernhardt, Oct 17, 2007
  2. Morten WelinderOct 17, 2007
  3. Brian GernhardtOct 17, 2007
  4. Lars HjemliOct 17, 2007
  5. Brian GernhardtOct 17, 2007
  6. Lars HjemliOct 17, 2007
  7. Jan HudecOct 18, 2007
  8. Frank LichtenheldOct 17, 2007
  9. Frank LichtenheldOct 17, 2007
  10. Brian GernhardtOct 17, 2007
  11. Shawn O. PearceOct 18, 2007
  12. Frank LichtenheldOct 18, 2007

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.