fix typo in git-am manpage
[gitweb.git] / receive-pack.c
index 7d263262d3b593b645c73b37b63356bfdea42d7f..ea6872e46f8707b2f2fe6d77ed449a3f8471792a 100644 (file)
@@ -158,7 +158,10 @@ static int update(struct command *cmd)
                        cmd->error_string = "failed to lock";
                        return error("failed to lock %s", name);
                }
-               write_ref_sha1(lock, new_sha1, "push");
+               if (write_ref_sha1(lock, new_sha1, "push")) {
+                       cmd->error_string = "failed to write";
+                       return -1; /* error() already called */
+               }
                fprintf(stderr, "%s: %s -> %s\n", name, old_hex, new_hex);
        }
        return 0;
@@ -429,7 +432,6 @@ int main(int argc, char **argv)
        if (is_repository_shallow())
                die("attempt to push into a shallow repository");
 
-       setup_ident();
        git_config(receive_pack_config);
 
        if (0 <= transfer_unpack_limit)