docs: update 64-bit core.packedGitLimit default
[gitweb.git] / sha1_file.c
index 2270f36a2b12d9f4b2f4c0cb2d8c5b5386aac142..1577e2d7dd4f38462b7b33c02b888eed3f4ca2c6 100644 (file)
@@ -3481,6 +3481,8 @@ int has_sha1_file_with_flags(const unsigned char *sha1, int flags)
 {
        struct pack_entry e;
 
+       if (!startup_info->have_repository)
+               return 0;
        if (find_pack_entry(sha1, &e))
                return 1;
        if (has_loose_object(sha1))