| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Update the status::renames test to create an NFD format filename in the
core.precomposedunicode tests.
Previously, we would create an NFC format filename. This was to take
advantage of HFS+ filesystems, which always use canonically decomposed
formats, and would actually write the filename to disk as an NFD
filename. So previously, we could create an NFC filename, but read it
normally as an NFD filename.
But APFS formats do not force canonically decomposed formats for
filenames, so creating an NFC filename does not get converted to NFD.
Instead, the filename will be written in NFC format. Our test,
therefore, does not work - when we write an NFC filename, it will
_remain_ NFC.
Update the test to write NFD always. This will ensure that the file
will actually be canonically decomposed on all platforms: HFS+, which
forces NFD, and APFS, which does not.
Thus, our test will continue to ensure that an NFD filename is
canonically precomposed on all filesystems.
|
|\
| |
| | |
branch: refuse creating branches named 'HEAD'
|
| |
| |
| |
| |
| |
| |
| |
| | |
Since a625b092c (branch: correctly reject refs/heads/{-dash,HEAD},
2017-11-14), which is included in v2.16.0, upstream git refuses to
create branches which are named HEAD to avoid ambiguity with the
symbolic HEAD reference. Adjust our own code to match that behaviour and
reject creating branches names HEAD.
|
|\ \
| | |
| | | |
refs: include " sorted " in our packed-refs header
|
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
This lets git know that we do in fact have written our packed-refs file
sorted (which is apparently not necessarily the case) and it can then use the
new-ish mmaped access which lets it avoid significant amounts of effort parsing
potentially large files to get to a single piece of data.
|
|\ \ \
| | | |
| | | | |
message: update docs for git_message_prettify
|
| | |/
| |/|
| | |
| | |
| | |
| | |
| | |
| | | |
We used to hard-code the octothorpe as the comment character and the
documentation still mentions this even though we accept the comment character as
a parameter.
Update the line to indicate this and clean up the first paragraph a bit.
|
|\ \ \
| |/ /
|/| | |
tests: online::clone: fix memory leak due to not freeing URL
|
|/ / |
|
|\ \
| | |
| | | |
Implement message trailer parsing API
|
| | | |
|
| | | |
|
| | | |
|
| | | |
|
| | | |
|
| |\ \
| | |/ |
|
| | | |
|
| | | |
|
| | | |
|
| | | |
|
| | | |
|
| |\ \ |
|
| | | | |
|
| | | | |
|
| | | | |
|
| | | |
| | | |
| | | |
| | | |
| | | | |
This is implemented in trailer.c and borrows a large amount of logic
from Git core to ensure compatibility.
|
|\ \ \ \
| |_|_|/
|/| | | |
Memory leaks
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
The test refs::iterator::foreach_name iterates through every reference
and copies its name into a local vector. While the test makes sure to
free the vector afterwards, the copied reference names are not being
free'd. Fix that.
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
References passed to the callback function of `git_reference_foreach`
are expected to be owned by the callback. As such, they are never being
freed by `git_reference_foreach`, but will have to be freed by the
caller. This small detail is never mentioned in the function's
documentation, though, making it easy to get wrong. Document this to
make it discoverable.
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
Upon downloading the pack file, the local transport will iterate through
every reference using `git_reference_foreach`. The function is a bit
tricky though in that it requires the passed callback to free the
references, which does not currently happen.
Fix the memory leak by freeing all passed references in the callback.
|
|/ / /
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Two tests in network::fetchlocal explicitly set a cleanup function to
free and remove the created sandbox repositories. This is not necessary,
though, as the cleanup function executed after each test already takes
care of cleaning up after them. Remove the code to avoid needless code
duplication.
|
|\ \ \
| | | |
| | | | |
travis: fetch trusty dependencies from Bintray
|
| | | |
| | | |
| | | | |
The VM on Travis apparently will still proceed, but it's good practice.
|
| | | |
| | | |
| | | |
| | | | |
The trusty dependencies are now hosted on Bintray.
|
|\ \ \ \
| |/ / /
|/| | | |
cmake: use a FEATURE_SUMMARY call compatible with 3.0.2
|
|/ / /
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
When we print features, we make an effort to support all the way back to
pre-3.0. However, in the code for versions from 3 onward we call
`FEATURE_SUMMARY` with multiple kinds of elements to print in the same line.
This is only supported in CMake 3.1 and later, making the rather popular CMake
3.0.2 unable to build the library.
Use a single kind of element per invocation. This means we need to provide a
"description" text, which CMake provides for us if provide multiple kinds of
elements.
|
|\ \ \
| | | |
| | | | |
Make sure to include 'openssl' as a dep when building statically with SHA1DC
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
We might want OpenSSL to be the implementation for SHA-1 and/or TLS. If we only
want it for TLS (e.g. we're building with the collision-detecting SHA-1
implementation) then we did not indicate this to the systems including us a
static library.
Add OpenSSL to the list also during the TLS decision to make sure we say we
should link to it if we use it for TLS.
|
|/ / /
| | |
| | |
| | |
| | |
| | | |
It is indeed a list of dependencies for those which include the static archive.
This is in preparation for adding two possible places where we might add openssl
as a dependency.
|
|\ \ \
| | | |
| | | | |
cmake: move the rule to find static archives close to building clar
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
If we're building static libraries, we want to use that for building our clar
binary. This is done in 49551254 (2017-09-22; cmake: use static dependencies
when building static libgit2) but that commit included the rule too early,
making it affect the search for iconv, meaning we did not find it when we were
building a static libgit2.
Move the rule to just before building clar, after we've included the rules for
building the library itself. This lets us find and link to the dynamic libiconv.
|
|\ \ \ \
| |/ / /
|/| | | |
cmake: allow explicitly choosing SHA1 backend
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
Right now, if SHA1DC is disabled, the SHA1 backend is mostly chosen
based on which system libgit2 is being compiled on and which libraries
have been found. To give developers and distributions more choice,
enable them to request specific backends by passing in a
`-DSHA1_BACKEND=<BACKEND>` option instead. This completely replaces the
previous auto-selection.
|
| | |/
| |/|
| | |
| | |
| | |
| | |
| | | |
Upstream git.git has changed their default SHA1 implementation to the
collision-detection algorithm SHA1DC in commit e6b07da27 (Makefile: make
DC_SHA1 the default, 2017-03-17). To match upstream, align ourselves and
switch over to SHA1DC by default.
|
|\ \ \
| | | |
| | | | |
Execute stale tests
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
Some tests shall be run against our own SSH server we spin up in Travis.
As those need to be run separate from our previous tests which run
against git-daemon, we have to do this in a separate step. Instead of
bundling all that knowledge in the CI script, move it into the test
build instructions by creating a new test target.
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
Right now, we test our credential callback code twice, once via SSH on
localhost and once via a non-existent GitHub repository. While the first
URL makes sense to be configurable, it does not make sense to hard-code
the non-existing repository, which requires us to call tests multiple
times. Instead, we can just inline the URL into another set of tests.
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
We support two types of passing credentials to the proxy, either via the
URL or explicitly by specifying user and password. We test these types
by modifying the proxy URL and executing the tests twice, which is
in fact unnecessary and requires us to maintain the list of environment
variables and test executions across multiple CI infrastructures.
To fix the situation, we can just always pass the host, port, user and
password to the tests. The tests can then assemble the complete URL
either with or without included credentials, allowing us to test both
cases in-process.
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
Our performance tests (or to be more concrete, our single performance
test) are not built by default, as they are always #ifdef'd out. While
it is true that we don't want to run performance tests by default, not
compiling them at all may cause code rot and is thus an unfavorable
approach to handle this.
We can easily improve this situation: this commit removes the #ifdef,
causing the code to always be compiled. Furthermore, we add `-xperf` to
the default command line parameters of `generate.py`, thus causing the
tests to be excluded by default.
Due to this approach, we are now able to execute the performance tests
by passing `-sperf` to `libgit2_clar`. Unfortunately, we cannot execute
the performance tests on Travis or AppVeyor as they rely on history
being available for the libgit2 repository. As both do a shallow clone
only, though, this is not given.
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
The test `iterator::workdir::filesystem_gunk` is usually not executed,
as it is guarded by the environment variable "GITTEST_INVASIVE_SPEED"
due to its effects on speed. As such, it has become stale and does not
account for new references which have meanwhile been added to the
testrepo, causing it to fail. Fix this by raising the number of expected
references to 15.
|