git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
From: "brian m. carlson" <sandals@crustytoothpaste.net>
To: <git@vger.kernel.org>
Cc: "Junio C Hamano" <gitster@pobox.com>,
	"Matthias Rüster" <matthias.ruester@gmail.com>
Subject: [PATCH] bundle: improve message when unknown hash algorithm detected
Date: Sun, 12 Jul 2020 16:50:05 +0000	[thread overview]
Message-ID: <20200712165005.705979-1-sandals@crustytoothpaste.net> (raw)

The current code states "unknown hash algorithm length".  This is
slightly confusing, and moreover, we've gotten feedback that it's hard
to translate into other languages.  Since the case is that we cannot
detect the hash algorithm, let's just say that.  This is clearer and
more direct, reflects the intent of the code (which calls the function
detect_hash_algo just a few lines above), and will be easier to
translate.

Suggested-by: Matthias Rüster <matthias.ruester@gmail.com>
Signed-off-by: brian m. carlson <sandals@crustytoothpaste.net>
---
Matthias contacted me privately about this message and I thought since
we're still in the RC period, it would make sense to include this in to
help translators and those who aren't native speakers.

 bundle.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/bundle.c b/bundle.c
index 2a0d744d3f..69c807bda9 100644
--- a/bundle.c
+++ b/bundle.c
@@ -66,7 +66,7 @@ static int parse_bundle_header(int fd, struct bundle_header *header,
 		if (!header->hash_algo) {
 			header->hash_algo = detect_hash_algo(&buf);
 			if (!header->hash_algo) {
-				error(_("unknown hash algorithm length"));
+				error(_("unable to detect hash algorithm"));
 				status = -1;
 				break;
 			}

             reply	other threads:[~2020-07-12 16:50 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-07-12 16:50 brian m. carlson [this message]
2020-07-12 18:10 ` [PATCH] bundle: improve message when unknown hash algorithm detected Junio C Hamano

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

  List information: http://vger.kernel.org/majordomo-info.html

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20200712165005.705979-1-sandals@crustytoothpaste.net \
    --to=sandals@crustytoothpaste.net \
    --cc=git@vger.kernel.org \
    --cc=gitster@pobox.com \
    --cc=matthias.ruester@gmail.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.
Code repositories for project(s) associated with this public inbox

	https://80x24.org/mirrors/git.git

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 read-only IMAP folder(s) and NNTP newsgroup(s).