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

Re: [PATCH v2 2/3] builtin-status: submodule summary support

From
Johannes Sixt <johannes.sixt@telecom.at>
Date
Apr 12, 2008, 16:13 UTC
Message-ID
<200804121813.20050.johannes.sixt@telecom.at>
In-Reply-To
<7vtzi8owf9.fsf@gitster.siamese.dyndns.org>
On Saturday 12 April 2008 00:31, Junio C Hamano wrote:
Show 16 quoted lines
> Ping Yin <pkufranky@gmail.com> writes:
> > +static void wt_status_print_submodule_summary(struct wt_status *s)
> > +{
> > ...
> > +	memset(&sm_summary, 0, sizeof(sm_summary));
> > +	sm_summary.argv = argv;
> > +	sm_summary.env = env;
> > +	sm_summary.git_cmd = 1;
> > +	sm_summary.no_stdin = 1;
> > +	fflush(s->fp);
> > +	sm_summary.out = dup(fileno(s->fp));    /* run_command closes it */
> > +	run_command(&sm_summary);
>
> I recall we had some clean-up on how file descriptors are inherited and
> duped around when run_command() runs a subprocess.  Hannes, is this dup()
> consistent with how the things ought to be these days?
Yes, this dup() is required and correct.
-- Hannes
Previous: Ping Yin
Message 8 of 8 in “builtin-status: submodule summary support”
  1. builtin-status: submodule summary supportPing Yin, Apr 10, 2008
  2. 1/3 git-submodule summary: --for-status optionPing Yin, Apr 10, 2008
  3. 2/3 builtin-status: submodule summary supportPing Yin, Apr 10, 2008
  4. 3/3 buitin-status: Add tests for submodule summaryPing Yin, Apr 10, 2008
  5. Junio C HamanoApr 11, 2008
  6. Ping YinApr 12, 2008
  7. Ping YinApr 12, 2008
  8. Johannes SixtApr 12, 2008

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.