receive-pack: quarantine objects until pre-receive accepts
[gitweb.git] / commit.c
index ba6dee37aa36cc7141649deda6407012cd0f2724..856fd4aeeff654c45ba0a6149f9db2c22806e0cb 100644 (file)
--- a/commit.c
+++ b/commit.c
@@ -931,7 +931,7 @@ static int remove_redundant(struct commit **array, int cnt)
        }
 
        /* Now collect the result */
-       memcpy(work, array, sizeof(*array) * cnt);
+       COPY_ARRAY(work, array, cnt);
        for (i = filled = 0; i < cnt; i++)
                if (!redundant[i])
                        array[filled++] = work[i];
@@ -1511,9 +1511,9 @@ static int verify_utf8(struct strbuf *buf)
 }
 
 static const char commit_utf8_warn[] =
-"Warning: commit message did not conform to UTF-8.\n"
-"You may want to amend it after fixing the message, or set the config\n"
-"variable i18n.commitencoding to the encoding your project uses.\n";
+N_("Warning: commit message did not conform to UTF-8.\n"
+   "You may want to amend it after fixing the message, or set the config\n"
+   "variable i18n.commitencoding to the encoding your project uses.\n");
 
 int commit_tree_extended(const char *msg, size_t msg_len,
                         const unsigned char *tree,
@@ -1566,7 +1566,7 @@ int commit_tree_extended(const char *msg, size_t msg_len,
 
        /* And check the encoding */
        if (encoding_is_utf8 && !verify_utf8(&buffer))
-               fprintf(stderr, commit_utf8_warn);
+               fprintf(stderr, _(commit_utf8_warn));
 
        if (sign_commit && do_sign_commit(&buffer, sign_commit))
                return -1;