{"thread":{"id":"7881","subject":"Do not barf on too long action description","startedAt":"2007-04-28T07:15:48Z","lastAt":"2007-04-28T07:15:48Z","messageCount":1,"participants":["Junio C Hamano"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"40648","messageId":"7v3b2lklzv.fsf_-_@assigned-by-dhcp.cox.net","threadId":"7881","inReplyTo":"20070428002638.GF18276@pasky.or.cz","subject":"Do not barf on too long action description","fromName":"Junio C Hamano","fromEmail":"junkio@cox.net","sentAt":"2007-04-28T07:15:48Z","receivedAt":"2007-04-28T07:15:48Z","isPatch":false,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Reflog message is primarily about easier identification, and\nleaving truncated entry is much better than dying.\n\nSigned-off-by: Junio C Hamano <junkio@cox.net>\n---\n builtin-fetch--tool.c |    4 +---\n 1 files changed, 1 insertions(+), 3 deletions(-)\n\ndiff --git a/builtin-fetch--tool.c b/builtin-fetch--tool.c\nindex 3145c01..1b04881 100644\n--- a/builtin-fetch--tool.c\n+++ b/builtin-fetch--tool.c\n@@ -42,9 +42,7 @@ static int update_ref(const char *action,\n \n \tif (!rla)\n \t\trla = \"(reflog update)\";\n-\tlen = snprintf(msg, sizeof(msg), \"%s: %s\", rla, action);\n-\tif (sizeof(msg) <= len)\n-\t\tdie(\"insanely long action\");\n+\tsnprintf(msg, sizeof(msg), \"%s: %s\", rla, action);\n \tlock = lock_any_ref_for_update(refname, oldval);\n \tif (!lock)\n \t\treturn 1;\n"}]}