From: Tarmigan <tarmigan+git@gmail.com>
To: Ilari Liusvaara <ilari.liusvaara@elisanet.fi>
Cc: git@vger.kernel.org
Subject: Re: [Updated PATCH 1/2] Report exec errors from run-command
Date: Thu, 31 Dec 2009 00:26:48 -0500 [thread overview]
Message-ID: <905315640912302126n1848c99cre0f9caa644041fad@mail.gmail.com> (raw)
In-Reply-To: <1262170338-11574-2-git-send-email-ilari.liusvaara@elisanet.fi>
On Wed, Dec 30, 2009 at 5:52 AM, Ilari Liusvaara
<ilari.liusvaara@elisanet.fi> wrote:
> Previously run-command was unable to report errors happening in exec
> call. Change it to pass errno from failed exec to errno value at
> return.
>
> The errno value passing can be done by opening close-on-exec pipe and
> piping the error code through in case of failure. In case of success,
> close-on-exec closes the pipe on successful exec and parent process
> gets end of file on read.
I was testing pu and 'git diff' and 'git log' would hang forever.
Bisecting pointed to v1 of this patch. But seeing that v2 was out, I
tried v2 of the patch, but the issue remains.
Tried on OSX and linux with the same results.
Here's a gdb backtrace on OSX at the point where I interrupted it:
(gdb) bt
#0 0x9923dbfe in read$UNIX2003 ()
#1 0x000b399b in start_command (cmd=0x10b300) at run-command.c:110
#2 0x00099452 in setup_pager () at pager.c:94
#3 0x0002196b in cmd_diff (argc=1, argv=0xbffff42c, prefix=0x0) at
builtin-diff.c:316
#4 0x00002a2a in run_builtin [inlined] () at git.c:257
#5 0x00002a2a in handle_internal_command (argc=1, argv=0xbffff42c) at git.c:401
#6 0x00002cab in main (argc=1, argv=0xbffff42c) at git.c:443
and on linux:
(gdb) bt
#0 0x0000003530a0d590 in __read_nocancel () from /lib64/libpthread.so.0
#1 0x0000000000494858 in start_command (cmd=0x71ed60) at run-command.c:93
#2 0x000000000047daf8 in setup_pager () at pager.c:94
#3 0x000000000041d83f in cmd_diff (argc=1, argv=0x7fff256f9fe0, prefix=0x0)
at builtin-diff.c:316
#4 0x0000000000403ced in handle_internal_command (argc=1, argv=0x7fff256f9fe0)
at git.c:257
#5 0x0000000000403f26 in main (argc=1, argv=0x7fff256f9fe0) at git.c:445
Thanks,
Tarmigan
next prev parent reply other threads:[~2009-12-31 5:27 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-12-30 10:52 [Updated PATCH 0/2] Improve remote helpers exec error reporting Ilari Liusvaara
2009-12-30 10:52 ` [Updated PATCH 1/2] Report exec errors from run-command Ilari Liusvaara
2009-12-30 13:47 ` Erik Faye-Lund
2009-12-31 5:26 ` Tarmigan [this message]
2009-12-31 10:48 ` Ilari Liusvaara
2009-12-31 14:44 ` Tarmigan
2009-12-30 10:52 ` [Updated PATCH 2/2] Improve transport helper exec failure reporting Ilari Liusvaara
2009-12-31 15:44 ` Johannes Sixt
2009-12-31 16:59 ` Ilari Liusvaara
2009-12-31 17:48 ` Johannes Sixt
2009-12-31 18:24 ` Ilari Liusvaara
2009-12-31 18:44 ` Johannes Sixt
2010-01-01 0:34 ` Johannes Sixt
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=905315640912302126n1848c99cre0f9caa644041fad@mail.gmail.com \
--to=tarmigan+git@gmail.com \
--cc=git@vger.kernel.org \
--cc=ilari.liusvaara@elisanet.fi \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).