commit 78527a0aa079d64a0cbe7def60d689e2fef5beb5 from: Stefan Sperling date: Wed May 22 09:13:53 2019 UTC move a comment to a better place and expand it commit - cc79381d1af8e783b6164745018a174399f46004 commit + 78527a0aa079d64a0cbe7def60d689e2fef5beb5 blob - 4b1cab455691db7d86ef399b4e219d16bad3e26c blob + 032ff72f4376333899d3edb42326d5e6877f2fa2 --- got/got.c +++ got/got.c @@ -2375,7 +2375,6 @@ collect_commit_logmsg(struct got_pathlist_head *commit goto done; } - /* remove comments */ *logmsg = malloc(st2.st_size + 1); if (*logmsg == NULL) { err = got_error_from_errno("malloc"); @@ -2393,7 +2392,7 @@ collect_commit_logmsg(struct got_pathlist_head *commit if (!content_changed && strcmp(buf, initial_content) != 0) content_changed = 1; if (buf[0] == '#' || (len == 0 && buf[0] == '\n')) - continue; + continue; /* remove comments and leading empty lines */ len = strlcat(*logmsg, buf, st2.st_size); } fclose(fp);