grammofix in user-facing messages
[gitweb.git] / builtin / commit.c
index 72eb3beb36cd06f6e41d80d5761a953a1c3a1d56..59c91ea1a48b98845f5f197a5640c8887d29cd8b 100644 (file)
@@ -420,8 +420,7 @@ static char *prepare_index(int argc, const char **argv, const char *prefix,
                        die(_("cannot do a partial commit during a cherry-pick."));
        }
 
-       memset(&partial, 0, sizeof(partial));
-       partial.strdup_strings = 1;
+       string_list_init(&partial, 1);
        if (list_paths(&partial, !current_head ? NULL : "HEAD", prefix, &pathspec))
                exit(1);
 
@@ -702,7 +701,7 @@ static int prepare_to_commit(const char *index_file, const char *prefix,
                char *buffer;
                buffer = strstr(use_message_buffer, "\n\n");
                if (buffer)
-                       strbuf_add(&sb, buffer + 2, strlen(buffer + 2));
+                       strbuf_addstr(&sb, buffer + 2);
                hook_arg1 = "commit";
                hook_arg2 = use_message;
        } else if (fixup_message) {
@@ -1779,7 +1778,7 @@ int cmd_commit(int argc, const char **argv, const char *prefix)
 
        if (commit_index_files())
                die (_("Repository has been updated, but unable to write\n"
-                    "new_index file. Check that disk is not full or quota is\n"
+                    "new_index file. Check that disk is not full and quota is\n"
                     "not exceeded, and then \"git reset HEAD\" to recover."));
 
        rerere(0);