summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* test: completely ignored diff is emptyethomson/diff_failEdward Thomson2021-05-191-0/+39
|
* Merge branch 'pr/5853'Edward Thomson2021-05-194-0/+43
|\
| * diff: test ignore-blank-linesEdward Thomson2021-05-181-0/+35
| |
| * diff:add option to ignore blank line changesyuuri2021-05-013-0/+8
| |
* | Merge pull request #5892 from libgit2/ethomson/memleakEdward Thomson2021-05-184-1/+19
|\ \ | | | | | | tests: clean up memory leak, fail on leak for win32
| * | tests: clean up refs::races zero oid testEdward Thomson2021-05-181-1/+3
| | |
| * | tests: exit with error on win32 leakcheckEdward Thomson2021-05-183-0/+16
|/ /
* | Merge pull request #5852 from implausible/httpclient/skip-entire-bodyEdward Thomson2021-05-161-4/+9
|\ \ | | | | | | Fix issues with Proxy Authentication after httpclient refactor
| * | httpclient: no proxy creds in requests if proxy is CONNECT typeTyler Ang-Wanek2021-05-121-3/+8
| | |
| * | httpclient: git_http_client_skip_body should drain socket of bodyTyler Ang-Wanek2021-05-121-1/+1
| |/
* | Merge pull request #5850 from punkymaniac/comment-formatEdward Thomson2021-05-162-21/+16
|\ \ | | | | | | Fix documentation formatting
| * | Fix typopunkymaniac2021-04-221-1/+1
| | |
| * | Uniformise documentation return code separatorpunkymaniac2021-04-221-7/+7
| | |
| * | Fix documentation formattingpunkymaniac2021-04-221-13/+8
| |/ | | | | | | | | | | The return code description use '-' char as list of return value. But with the generation of the documentation the char '-' create an ambiguous return code value who seem an negative value.
* | Merge pull request #5831 from todaysoftware/bindings/libgit2-delphiEdward Thomson2021-05-161-0/+1
|\ \ | | | | | | Update README.md for additional Delphi bindings
| * | Update README.md for additional Delphi bindingstodaysoftware2021-03-261-0/+1
| | | | | | | | | Delphi/Free pascal bindings targeting the latest version of libgit2
* | | Merge branch 'zero_oid_in_old'Edward Thomson2021-05-163-1/+23
|\ \ \ | | | | | | | | | | | | Manually merging #5842
| * | | refs: test git_reference_create_matching failure for zero oidEdward Thomson2021-05-161-0/+3
| | | |
| * | | git_reference_create_matching: Treat all-zero OID as "must be absent"David Turner2021-04-203-1/+20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is pretty useful in avoiding races: I want to create a ref only if it doesn't already exist. I can't check first because of TOCTOU -- by the time I finish the check, someone else might have already created the ref. And I can't take a lock because then I can't do the create, since the create expects to take the lock. The semantics are inspired by git update-ref, which allows an all-zero old value to mean that the ref must not exist.
* | | | Merge pull request #5839 from staktrace/find_similarEdward Thomson2021-05-1315-2/+68
|\ \ \ \
| * | | | Add testcaseKartikaya Gupta2021-05-1214-0/+66
| | | | |
| * | | | diff: Fix bug in git_diff_find_similar.Kartikaya Gupta2021-05-121-2/+2
|/ / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When a split src gets turned into a rename, it should also lose the IS_RENAME_TARGET flag, so that it doesn't get processed in a subsequent iteration as a rename target. Doing so can cause an assertion failure because it no longer has the SPLIT flag. Fixes #5811.
* | | | Merge pull request #5860 from libgit2/ethomson/buf_textEdward Thomson2021-05-1126-539/+468
|\ \ \ \ | | | | | | | | | | buf: remove unnecessary buf_text namespace
| * | | | buf: bom enum is in the buf namespaceEdward Thomson2021-05-115-25/+25
| | | | | | | | | | | | | | | | | | | | | | | | | Instead of a `git_bom_t` that a `git_buf` function returns, let's keep it `git_buf_bom_t`.
| * | | | buf: remove internal `git_buf_text` namespaceEdward Thomson2021-05-1126-532/+461
| | | | | | | | | | | | | | | | | | | | | | | | | The `git_buf_text` namespace is unnecessary and strange. Remove it, just keep the functions prefixed with `git_buf`.
* | | | | Merge pull request #5859 from libgit2/ethomson/filter_bufEdward Thomson2021-05-1110-118/+209
|\ \ \ \ \ | |/ / / / |/| | | | filter: stop taking git_buf as user input
| * | | | filter: internal git_buf filter handling functionEdward Thomson2021-05-065-8/+34
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Introduce `git_filter_list__convert_buf` which behaves like the old implementation of `git_filter_list__apply_data`, where it might move the input data buffer over into the output data buffer space for efficiency. This new implementation will do so in a more predictible way, always freeing the given input buffer (either moving it to the output buffer or filtering it into the output buffer first). Convert internal users to it.
| * | | | filter: deprecate git_filter_list_apply_to_dataEdward Thomson2021-05-066-97/+111
| | | | | | | | | | | | | | | | | | | | | | | | | Deprecate `git_filter_list_apply_to_data` as it takes user input as a `git_buf`. Users should use `git_filter_list_apply_to_buffer` instead.
| * | | | filter: introduce git_filter_list_apply_to_bufferEdward Thomson2021-05-062-1/+16
| | | | | | | | | | | | | | | | | | | | | | | | | Provide a filter application mechanism that takes a user-provided string and length, instead of a `git_buf`.
| * | | | filter: remove git_buf sharing in `git_filter_list_apply_to_data`Edward Thomson2021-05-062-24/+20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The API `git_filter_list_apply_to_data` shares data between its out and in parameters to avoid unnecessarily copying it when there are no filters to apply. However, it does so in a manner that is potentially confusing, leaving both `git_buf`s populated with data. This is risky for end-users who have to know how to deal with this. Instead, we remove this optimization - users who want to avoid unnecessary copies can use the longstanding streaming API or check the filter status before invoking the filters.
| * | | | filter: deprecate git_filter_list_stream_dataEdward Thomson2021-05-063-13/+53
|/ / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | `git_filter_list_stream_data` takes user input in a `git_buf`. `git_buf` should only be used when libgit2 itself needs to allocate data and returned to a user that they can free when they wish. Replace it with `git_filter_list_stream_buffer` that takes a data buffer and length.
* | | | Merge pull request #5858 from libgit2/ethomson/memleaksEdward Thomson2021-05-063-0/+5
|\ \ \ \ | | | | | | | | | | test: clean up memory leaks
| * | | | test: clean up memory leaksEdward Thomson2021-05-063-0/+5
| | | | |
* | | | | Merge pull request #5857 from libgit2/ethomson/longpathsEdward Thomson2021-05-066-67/+129
|\ \ \ \ \ | |/ / / / |/| | | | Support `core.longpaths` on Windows
| * | | | win32: add file and get status on a long pathEdward Thomson2021-05-061-1/+31
| | | | |
| * | | | win32: ensure core.longpaths is honored for workdir pathsEdward Thomson2021-05-061-0/+4
| | | | |
| * | | | path: bump most Win32 unicode buffer sizes from MAX_PATH to GIT_PATH_MAXIan Hattendorf2021-05-054-46/+33
| | | | |
| * | | | clar: support long paths on WindowsEdward Thomson2021-05-052-20/+61
|/ / / /
* | | | Merge pull request #5855 from libgit2/ethomson/ciEdward Thomson2021-05-041-2/+2
|\ \ \ \ | | | | | | | | | | ci: use GitHub for storing mingw-w64 build dependency
| * | | | ci: use GitHub for storing mingw-w64 build dependencyEdward Thomson2021-05-041-2/+2
|/ / / /
* | | | Merge pull request #5823 from libgit2/ethomson/path_validationEdward Thomson2021-05-0241-506/+1039
|\ \ \ \ | |_|_|/ |/| | | Working directory path validation
| * | | repo: validate repository pathsEdward Thomson2021-04-282-7/+65
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Ensure that a repository's path (at initialization or open time) is valid. On Windows systems, this means that the longest known path beneath the repository will fit within MAX_PATH: this is a lock file for a loose object within the repository itself. Other paths, like a very long loose reference, may fail to be opened after the repository is opened. These variable length paths will be checked when they are accessed themselves. This new functionality is done at open to prevent needlessly checking every file in the gitdir (eg, `MERGE_HEAD`) for its length when we could instead check once at repository open time.
| * | | repo: factor the commondir detectionEdward Thomson2021-04-281-28/+41
| | | |
| * | | refs: ensure loose refs adhere to path validationEdward Thomson2021-04-282-30/+94
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | On Windows, we need to enforce MAX_PATH for loose references and their reflogs. Ensure that any path - including the lock file - would fit within the 260 character maximum. We do not honor core.longpaths for loose reference files or reflogs. core.longpaths only applies to paths in the working directory.
| * | | path: don't join paths in git_path_find_dirEdward Thomson2021-04-283-11/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Let `git_path_find_dir` simply take a `git_buf` that contains a directory or a file, instead of trying to both join a path AND then deal with prettifying it or its basename. This allows consumers to join paths themselves (and apply any necessary rules - like fitting within MAX_PATH).
| * | | worktree: validate worktree pathsEdward Thomson2021-04-281-2/+5
| | | | | | | | | | | | | | | | | | | | Worktree paths need to fix within MAX_PATH always, regardless of `core.longpaths` setting.
| * | | submodule: validate path lengthsEdward Thomson2021-04-281-27/+27
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Validate that working directory paths honor `core.longpaths` where appropriate. Paths to the submodule gitdirs must always honor the operating system length restrictions; `core.longpaths` does not affect gitdir paths.
| * | | iterator: validate workdir pathsEdward Thomson2021-04-281-4/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Supply the repository for the filesystem and workdir iterators - for workdir iterators, this is non-null and we can lookup the core.longpaths configuration option. (For regular filesystem iterators, this is NULL, so core.longpaths does not apply.)
| * | | ignore: validate workdir paths for ignore filesEdward Thomson2021-04-281-7/+10
| | | |
| * | | attr: validate workdir paths for attribute filesEdward Thomson2021-04-287-16/+30
| | | | | | | | | | | | | | | | | | | | | | | | We should allow attribute files - inside working directories - to have names longer than MAX_PATH when core.longpaths is set. `git_attr_path__init` takes a repository to validate the path with.