| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
|
|
|
|
|
|
|
|
| |
Instead of bailing out with an error, this sets tagger to NULL when
the field is missing from the object.
This makes it possible to inspect tags like this one:
http://git.kernel.org/?p=git/git.git;a=tag;h=f25a265a342aed6041ab0cc484224d9ca54b6f41
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The v0.99 tag in the Git repo triggers this behavior:
http://git.kernel.org/?p=git/git.git;a=tag;h=d6602ec5194c87b0fc87103ca4d67251c76f233a
Ideally, we'd allow the tag to be instantiated even though the tagger
field is missing, but this at the very least prevents libgit2 from
crashing.
To test this bug, a new repository has been added based on the test
branch in testrepo.git. It contains a "e90810b" tag that looks like
this:
object e90810b8df3e80c413d903f631643c716887138d
type commit
tag e90810b
This is a very simple tag.
|
|
|
|
|
|
|
|
|
| |
This ensures commit->message is always non-NULL, even if the commit
message is empty or consists of only a newline.
One such commit can be found in the wild in the jQuery repository:
https://github.com/jquery/jquery/commit/25b424134f9927a5bf0bab5cba836a0aa6c3cfc1
|
|
|
|
|
|
|
|
| |
The documentation is a bit misleading. The subsection name is always
case-sensitive, but with a [section.subsection] header, the subsection
is transformed to lowercase when the configuration is parsed.
Signed-off-by: Carlos Martín Nieto <carlos@cmartin.tk>
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
git_repository_config wants to take the global and system paths again
so that one can be explicit if needed.
The git_repository_config_autoload function is provided for the cases
when it's good enough for the library to guess where those files are
located.
Signed-off-by: Carlos Martín Nieto <carlos@cmartin.tk>
|
|\
| |
| | |
t18-status.c: fix unused warnings
|
| |
| |
| |
| | |
Signed-off-by: schu <schu-github@schulog.org>
|
|/
|
|
| |
This reverts commit e1b86444676b70154bf8ab450d429bdef57a8276.
|
|
|
|
|
|
|
|
| |
wide values
Should fix issue #419.
Signed-off-by: nulltoken <emeric.fermas@gmail.com>
|
| |
|
|
|
|
|
| |
Signed-off-by: nulltoken <emeric.fermas@gmail.com>
Signed-off-by: schu <schu-github@schulog.org>
|
| |
|
|\
| |
| | |
Add more -W flags to CFLAGS
|
| |
| |
| |
| | |
Signed-off-by: Kirill A. Shutemov <kirill@shutemov.name>
|
| |
| |
| |
| | |
Signed-off-by: Kirill A. Shutemov <kirill@shutemov.name>
|
|\ \
| | |
| | | |
git_repository_config: open global config file automatically
|
| |/
| |
| |
| |
| |
| | |
If the global configuration file is missing, it is ignored.
Signed-off-by: Carlos Martín Nieto <carlos@cmartin.tk>
|
| | |
|
| |
| |
| |
| | |
Provided the tests fail (which they should not) and the callback is invoked too many times, this prevents the tests from segfaulting.
|
| |
| |
| |
| | |
...Ops, I broke the old test when porting it to Clay.
|
| | |
|
| |
| |
| |
| |
| | |
- Should increase performance through usage of a walker
- No callback invocation for unaltered entries
|
| |
| |
| |
| |
| |
| | |
- fix retrieval of a file status when working against a newly initialized repository
- reduce memory pressure
- prevents a directory from being tested
|
|/
|
|
| |
line-feed conversion
|
|
|
|
|
|
|
| |
There is no need in STRLEN macros. Compilers can do this trivial
optimization on its own.
Signed-off-by: Kirill A. Shutemov <kirill@shutemov.name>
|
|
|
|
|
|
|
| |
Rather than returning the OIDs out of the reflog as string return them
as git_oid.
Signed-off-by: schu <schu-github@schulog.org>
|
| |
|
|
|
|
|
|
| |
discover0 tried to stat a non existing directory. Create it beforehand.
Signed-off-by: schu <schu-github@schulog.org>
|
|
|
|
| |
resources folder
|
| |
|
|
|
|
| |
Signed-off-by: Carlos Martín Nieto <carlos@cmartin.tk>
|
|
|
|
| |
Replace all must_pass(strcmp()) by must_be_true(strcmp()==0)
|
|
|
|
|
|
|
|
| |
git_signature_new() and git_signature_now() currently don't return error
codes. Change the API to return error codes and not pointers to let the
user handle errors properly.
Signed-off-by: schu <schu-github@schulog.org>
|
|
|
|
| |
Signed-off-by: schu <schu-github@schulog.org>
|
|
|
|
| |
Update unit test accordingly : no need to close
|
|
|
|
|
|
|
| |
Disallow NULL as ancestor OID when writing a reflog entry for an
existing reference.
Signed-off-by: schu <schu-github@schulog.org>
|
|
|
|
|
|
|
|
| |
When you open an index with git_index_open, the file is read before
the function returns. Thus, calling git_index_read after that is
useless.
Signed-off-by: Carlos Martín Nieto <cmn@elego.de>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
/home/kas/git/public/libgit2/tests/t00-core.c: In function ‘test_cmp’:
/home/kas/git/public/libgit2/tests/t00-core.c:78:10: warning: cast discards ‘__attribute__((const))’ qualifier from pointer target type [-Wcast-qual]
/home/kas/git/public/libgit2/tests/t00-core.c:78:22: warning: cast discards ‘__attribute__((const))’ qualifier from pointer target type [-Wcast-qual]
/home/kas/git/public/libgit2/tests/t07-hashtable.c: In function ‘hash_func’:
/home/kas/git/public/libgit2/tests/t07-hashtable.c:42:7: warning: cast discards ‘__attribute__((const))’ qualifier from pointer target type [-Wcast-qual]
/home/kas/git/public/libgit2/tests/t08-tag.c: In function ‘_gittest__write0’:
/home/kas/git/public/libgit2/tests/t08-tag.c:141:21: warning: cast discards ‘__attribute__((const))’ qualifier from pointer target type [-Wcast-qual]
/home/kas/git/public/libgit2/tests/t08-tag.c: In function ‘_gittest__write2’:
/home/kas/git/public/libgit2/tests/t08-tag.c:192:21: warning: cast discards ‘__attribute__((const))’ qualifier from pointer target type [-Wcast-qual]
/home/kas/git/public/libgit2/tests/t08-tag.c: In function ‘_gittest__write3’:
/home/kas/git/public/libgit2/tests/t08-tag.c:227:21: warning: cast discards ‘__attribute__((const))’ qualifier from pointer target type [-Wcast-qual]
/home/kas/git/public/libgit2/tests/t04-commit.c: In function ‘_gittest__write0’:
/home/kas/git/public/libgit2/tests/t04-commit.c:650:21: warning: cast discards ‘__attribute__((const))’ qualifier from pointer target type [-Wcast-qual]
/home/kas/git/public/libgit2/tests/t04-commit.c:651:21: warning: cast discards ‘__attribute__((const))’ qualifier from pointer target type [-Wcast-qual]
/home/kas/git/public/libgit2/tests/t04-commit.c: In function ‘_gittest__root0’:
/home/kas/git/public/libgit2/tests/t04-commit.c:723:21: warning: cast discards ‘__attribute__((const))’ qualifier from pointer target type [-Wcast-qual]
/home/kas/git/public/libgit2/tests/t04-commit.c:724:21: warning: cast discards ‘__attribute__((const))’ qualifier from pointer target type [-Wcast-qual]
/home/kas/git/public/libgit2/tests/t12-repo.c: In function ‘write_file’:
/home/kas/git/public/libgit2/tests/t12-repo.c:360:24: warning: cast discards ‘__attribute__((const))’ qualifier from pointer target type [-Wcast-qual]
Signed-off-by: Kirill A. Shutemov <kirill@shutemov.name>
|
|\
| |
| | |
More memory leaks
|
| |
| |
| |
| | |
Signed-off-by: Carlos Martín Nieto <carlos@cmartin.tk>
|
|/ |
|
| |
|
|
|
|
| |
Signed-off-by: Carlos Martín Nieto <cmn@elego.de>
|
| |
|
| |
|
| |
|
|
|
|
|
|
| |
- Use a space to separate oids and signature
- Enforce test coverage
- Make test run in a temporary folder in order not to alter the test repository
|
|
|
|
|
|
|
|
| |
The `hashfile` function has been moved to ODB, next to `git_odb_hash`.
Global state has been removed from the dirent call in `status.c`,
because global state is killing the rainforest and causing global
warming.
|