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

Re: [RFC] Cleaning up die() error messages

From
Junio C Hamano <junkio@cox.net>
Date
Oct 10, 2005, 19:04 UTC
Message-ID
<7vzmph42j2.fsf@assigned-by-dhcp.cox.net>
In-Reply-To
<20051010105008.GB30202@gentoo.org>
Elfyn McBratney <beu@gentoo.org> writes:
> (Of course, the C parts (`prog' and `set_prog_name()') would go into a
> header, and not in every single C source file. ;)
>
> So, any thoughts/comments/flames? :)

I do not have objections to either one, except I tend to prefer programs that tells its full path when erroring out, which helps me identify "Oops, my path was screwed up and I am not testing the right one" case.

One thing to keep in mind is how badly this C part might interact with the libification effort going on underwater. Since current code Smurf is working on is based on 0.99.6 and many small pieces need to be reviewed anyway, I am not so much worried about forward porting the changes. But some die()s that are in the parts that will be moved to the common library code would also want to use this prog global somehow.

But that would not be too much of a problem. Worst case, we force the library clients to do set_prog_name(), or initialize prog to "(unnamed)", or do both.

Previous: Elfyn McBratneyNext: Matthias Urlichs
Message 2 of 13 in “[RFC] Cleaning up die() error messages”
  1. Elfyn McBratneyOct 10, 2005
  2. Junio C HamanoOct 10, 2005
  3. Matthias UrlichsOct 11, 2005
  4. H. Peter AnvinOct 11, 2005
  5. Matthias UrlichsOct 12, 2005
  6. H. Peter AnvinOct 12, 2005
  7. Junio C HamanoOct 12, 2005
  8. H. Peter AnvinOct 12, 2005
  9. Junio C HamanoOct 12, 2005
  10. Matthias UrlichsOct 12, 2005
  11. Daniel BarkalowOct 10, 2005
  12. Alex RiesenOct 11, 2005
  13. H. Peter AnvinOct 11, 2005

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.