Thread (1 message) 1 message, 1 author, 2016-08-24

Re: [PATCH 3/3] i18n: simplify numeric error reporting

From: Junio C Hamano <hidden>
Date: 2016-08-24 15:50:59
Subsystem: the rest · Maintainer: Linus Torvalds

Possibly related (same subject, not in this thread)

I'll squash this in to avoid compilation breakage.  We do not allow
decl-after-stmt.

Thanks.

 config.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/config.c b/config.c
index e33c703..0dfed68 100644
--- a/config.c
+++ b/config.c
@@ -652,10 +652,11 @@ int git_parse_ulong(const char *value, unsigned long *ret)
 NORETURN
 static void die_bad_number(const char *name, const char *value)
 {
+	const char * error_type = (errno == ERANGE)? _("out of range"):_("invalid unit");
+
 	if (!value)
 		value = "";
 
-	const char * error_type = (errno == ERANGE)? _("out of range"):_("invalid unit");
 	if (!(cf && cf->name))
 		die(_("bad numeric config value '%s' for '%s': %s"),
 		    value, name, error_type);
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help