From: "Carlos Rica" <jasampler@gmail.com>
To: "Junio C Hamano" <gitster@pobox.com>
Cc: git@vger.kernel.org, "Johannes Schindelin" <Johannes.Schindelin@gmx.de>
Subject: Re: [PATCH] Make verify-tag a builtin.
Date: Fri, 27 Jul 2007 21:51:41 +0200 [thread overview]
Message-ID: <1b46aba20707271251g7cf968a6o3840739dec548408@mail.gmail.com> (raw)
In-Reply-To: <7vr6mu2uo0.fsf@assigned-by-dhcp.cox.net>
2007/7/27, Junio C Hamano <gitster@pobox.com>:
> Carlos Rica <jasampler@gmail.com> writes:
> > Signal SIGPIPE is ignored because the program sometimes was
> > terminated because that signal when writing the input for gpg.
>
> This "sometimes" does not give confidence to readers, I am
> afraid.
>
> What is happening is perfectly normal, not "sometimes it gets
> the signal mysteriously, so we need to paper it over by ignoring
> it".
>
> You invoke gpg, giving it a file that is supposed to contain a
> detached signature, and start feeding the payload that ought to
> verify Ok with the signature. If the tag is not signed, after
> gpg has read the detached signature, it already knows that the
> signature will not verify and it can exit without reading the
> payload from its standard input. When you try to write the
> payload to the pipe, you would get SIGPIPE.
By using "sometimes" I was requesting an answer to this strange
behaviour (for me) to you and the mailing list. Now I could reproduce it
removing the call to signal and running this:
#!/bin/sh
echo "creating vtag1..."
git tag -s -m "a signed tag" vtag1
echo "creating vtag2..."
git tag -m "an annotated non-signed tag" vtag2
echo "creating vtag3..."
git tag -m "another annotated non-signed tag is " vtag3
# 141 returned sometimes when gpg got
# a non-signed file as detached signature:
# (it refuses to read from the input when
# no signature is given, sometimes)
for i in 1 2 3 4 5 6 7 8 9 10
do
./git verify-tag vtag1 vtag2 vtag3
echo "git verify-tag vtag1 vtag2 vtag3 exit code: $?"
echo
done
git tag -d vtag1
git tag -d vtag2
git tag -d vtag3
In my system, some of the tests give 141 and others give 1 as exit code.
Dscho said that it could depend on the CPU current load of the computer,
since he got always 141 as you said, so perhaps it's me.
next prev parent reply other threads:[~2007-07-27 19:51 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-07-27 4:07 [PATCH] Make verify-tag a builtin Carlos Rica
2007-07-27 7:05 ` Junio C Hamano
2007-07-27 19:51 ` Carlos Rica [this message]
2007-07-27 21:08 ` Junio C Hamano
2007-07-28 18:02 ` Carlos Rica
-- strict thread matches above, loose matches on Subject: below --
2007-07-23 0:20 Carlos Rica
2007-07-23 0:52 ` Johannes Schindelin
2007-07-23 21:21 ` Carlos Rica
2007-07-23 21:48 ` Johannes Schindelin
2007-07-23 22:31 ` Carlos Rica
2007-07-23 22:32 ` Johannes Schindelin
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=1b46aba20707271251g7cf968a6o3840739dec548408@mail.gmail.com \
--to=jasampler@gmail.com \
--cc=Johannes.Schindelin@gmx.de \
--cc=git@vger.kernel.org \
--cc=gitster@pobox.com \
/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).