src


Log

Author Commit Date CI Message
Edward Thomson 7d75e1c7 2020-04-05T19:28:13 reflog: use GIT_ASSERT
Edward Thomson 98a4f278 2020-04-05T21:38:42 refdb_fs: use GIT_ASSERT
Edward Thomson 690ff9cd 2020-04-05T19:17:58 rebase: use GIT_ASSERT
Edward Thomson 00e57f64 2020-04-05T19:15:11 reader: use GIT_ASSERT
Edward Thomson 8d66d57f 2020-04-05T19:20:01 refdb: use GIT_ASSERT
Edward Thomson 9cd6481e 2020-04-05T19:14:35 posix: use GIT_ASSERT
Edward Thomson 4b093e75 2020-04-05T18:36:23 pathspec: use GIT_ASSERT
Edward Thomson 3bb9916c 2020-04-05T17:33:06 odb_mempack: use GIT_ASSERT
Edward Thomson 1fa339be 2020-04-05T16:50:13 index: use GIT_ASSERT
Edward Thomson 3a6d04a3 2020-04-05T16:44:42 ignore: use GIT_ASSERT
Edward Thomson 9d1cfb2f 2020-04-05T17:32:52 odb_loose: use GIT_ASSERT
Edward Thomson 01c64945 2020-04-05T16:43:55 hashsig: use GIT_ASSERT
Edward Thomson 253a873b 2020-04-05T16:33:54 hash: use GIT_ASSERT
Edward Thomson 16b1a756 2020-04-05T18:33:55 path: use GIT_ASSERT
Edward Thomson 931fd6b0 2020-04-05T17:29:13 odb: use GIT_ASSERT
Edward Thomson 03623b47 2020-04-05T16:28:03 futils: use GIT_ASSERT
Edward Thomson bc54898f 2020-04-05T16:27:30 filter: use GIT_ASSERT
Edward Thomson 4300aa4b 2020-04-05T17:24:32 object: use GIT_ASSERT
Edward Thomson 33c5c513 2020-04-05T16:30:00 filebuf: use GIT_ASSERT
Edward Thomson a08bd547 2020-04-05T16:24:26 fetchhead: use GIT_ASSERT
Edward Thomson 2cfa31c4 2020-04-05T18:30:07 path: remove unused git_path_topdir
Edward Thomson 6718ad9f 2020-04-05T17:20:46 notes: use GIT_ASSERT
Edward Thomson 05816a98 2020-04-05T17:20:08 netops: use GIT_ASSERT
Edward Thomson 1a724625 2020-04-05T18:27:51 patch: use GIT_ASSERT
Edward Thomson ea7c807a 2020-04-05T17:18:46 net: use GIT_ASSERT
Edward Thomson a3e8b7cd 2020-04-05T17:18:20 mwindow: use GIT_ASSERT
Edward Thomson 4dba9303 2020-11-22T10:42:41 pack-objects: use GIT_ASSERT
Edward Thomson 69fb8979 2020-11-21T22:54:26 midx: use GIT_ASSERT
Edward Thomson f16f2927 2020-04-05T17:09:59 merge_file: use GIT_ASSERT
Edward Thomson 7cd0bf65 2020-04-05T18:26:52 pack: use GIT_ASSERT
Edward Thomson 61f33f3e 2020-04-05T17:08:42 merge_driver: use GIT_ASSERT
Edward Thomson c59fbafd 2020-04-05T17:06:37 merge: use GIT_ASSERT
Edward Thomson 9502f8e9 2020-04-05T19:13:07 pool: use GIT_ASSERT
Edward Thomson 87d37896 2020-04-05T17:35:19 oid: use GIT_ASSERT
Edward Thomson 237657f4 2020-04-05T17:03:41 map: use GIT_ASSERT
Edward Thomson 23e38fd3 2020-04-05T17:02:17 mailmap: use GIT_ASSERT
Edward Thomson a072a025 2020-04-05T17:34:12 odb_pack: use GIT_ASSERT
Edward Thomson 79b0c8c8 2020-11-21T23:29:29 iterator: use GIT_ASSERT
Edward Thomson cd2fe662 2020-04-05T16:56:55 indexer: use GIT_ASSERT
Edward Thomson 59565a05 2020-04-05T16:23:40 errors: use GIT_ASSERT
Edward Thomson 5d6c2f26 2020-04-05T14:59:54 diff: use GIT_ASSERT
Edward Thomson 81609902 2020-04-05T14:53:50 describe: use GIT_ASSERT
Edward Thomson 65c23e9c 2020-04-05T14:53:08 delta: use GIT_ASSERT
Edward Thomson 00974bca 2020-04-05T14:52:48 date: use GIT_ASSERT
Edward Thomson e7604da8 2020-04-05T14:51:56 config: use GIT_ASSERT
Edward Thomson 3b2153fe 2020-04-05T14:42:44 commit: use GIT_ASSERT
Edward Thomson d4384977 2020-04-05T14:38:20 clone: use GIT_ASSERT
Edward Thomson 5d8b75fa 2020-04-05T14:37:22 cherrypick: use GIT_ASSERT
Edward Thomson 266f26ed 2020-04-05T14:35:23 checkout: use GIT_ASSERT
Edward Thomson e0f3c33d 2020-04-05T11:22:19 buffer: git_buf_copy_cstr should return a value `git_buf_copy_cstr` is called with user-input, and wants to sanity-check that input. Allow it to return a value if the input was malformed in a way that we cannot cope.
Edward Thomson cb4bfbc9 2020-04-05T11:07:54 buffer: git_buf_sanitize should return a value `git_buf_sanitize` is called with user-input, and wants to sanity-check that input. Allow it to return a value if the input was malformed in a way that we cannot cope.
Edward Thomson a6dd5865 2020-04-05T10:23:20 buffer: use GIT_ASSERT
Edward Thomson 7d24070d 2020-04-05T10:14:28 branch: use GIT_ASSERT
Edward Thomson abb7a7e4 2020-04-05T10:11:34 blob: use GIT_ASSERT
Edward Thomson efab78cd 2020-04-05T10:09:11 blame: use GIT_ASSERT
Edward Thomson b44b262b 2020-04-05T10:07:09 attr_file: use GIT_ASSERT
Edward Thomson 7b2f94bf 2020-04-05T10:04:52 attr: use GIT_ASSERT
Edward Thomson c6e84bce 2020-04-05T09:49:28 apply: use GIT_ASSERT
Edward Thomson f60ebfcb 2020-04-04T23:31:05 annotated_commit: use GIT_ASSERT
Edward Thomson d9d86e41 2020-11-21T22:13:51 Merge pull request #5580 from libgit2/ethomson/win32_leakcheck msvc crtdbg -> win32 leakcheck
Edward Thomson 045748bb 2020-11-21T22:06:57 Merge pull request #5692 from rbmclean/master Add missing worktree_dir check and test case
Edward Thomson c8fe4da3 2020-11-21T22:06:03 Apply suggestions from code review
Edward Thomson 8aed4629 2020-07-12T18:43:22 cmake: rename MSVC_CRTDBG to WIN32_LEAKCHECK
Edward Thomson 51825c4f 2020-07-12T18:18:12 alloc: rename the win32 leakcheck allocator The win32 leakchecking system is now named win32_leakcheck. Update the allocator to match.
Edward Thomson 31654a34 2020-07-12T18:07:10 win32: consolidate leak checking initialization Move leak check initialization into git_win32_leakcheck_global_init, and call it on library initialization.
Edward Thomson cb4b3bdf 2020-07-12T17:49:42 win32: "crtdbg" is now "leakcheck" msvc crtdbg is a mouthfull that is not particularly indicative of what it does. Let's rename it to "win32 leakcheck".
Edward Thomson a6d151bf 2020-11-21T21:31:41 Merge pull request #5690 from lhchavez/fix-filelimit-compile-error Fix the `-DTHREADSAFE=OFF` build
Reginald McLean 6405ce29 2020-11-06T11:36:25 worktree: Added worktree_dir check Fixes #5280
lhchavez aa532e29 2020-10-31T07:51:03 Fix the `-DTHREADSAFE=OFF` build This change avoids using the `(void)0` construct for some of the mutex `#define`s, since that makes the "return type" of those "functions" to be `void` instead of `int`.
Sven Strickroth 0caa4655 2020-09-09T10:48:00 Add git_tag_name_is_valid Signed-off-by: Sven Strickroth <email@cs-ware.de>
Sven Strickroth fe11160c 2020-09-08T21:05:18 Add git_branch_name_is_valid Signed-off-by: Sven Strickroth <email@cs-ware.de>
Edward Thomson c7143d7c 2020-10-11T13:56:16 remote: deprecate git_remote_is_valid_name
Edward Thomson 55a7117d 2020-10-11T13:55:44 remote: use git_remote_name_is_valid
Edward Thomson 023ebb9a 2020-10-11T13:48:07 refs: introduce git_remote_name_is_valid Provide a function that can check remote name validity but can also signal when an error occurs. Use the name "name_is_valid", which is more suggestive of checking a given name, rather than "is_valid_name", which suggests that the function checks the validity of the current remote's name.
Edward Thomson 68e35588 2020-10-11T13:35:35 refspec: return GIT_EINVALIDSPEC for invalid specs Disambiguate invalid specifications in `git_refspec__parse` so that callers can determine the difference between invalid specifications and actual errors. No call sites wil propagagte this new error message to an end-user, so there is no user-facing API change.
Edward Thomson 63460fe4 2020-10-11T13:21:13 refs: deprecate git_reference_is_valid_name
Edward Thomson b52bb4d4 2020-10-11T13:20:52 refs: use git_reference_name_is_valid
Edward Thomson 29715d40 2020-10-11T12:50:52 refs: introduce git_reference_name_is_valid Provide a function that can check reference name validity but can also signal when an error occurs. Use the name "name_is_valid", which is more suggestive of checking a given name, rather than "is_valid_name", which suggests that the function checks the validity of the current reference's name.
Edward Thomson d70979cf 2020-10-11T12:26:34 refs: error checking in internal name validation Move `git_reference__is_valid_name` to `git_reference__name_is_valid`, which returns errors and sets an out boolean parameter.
Edward Thomson 246bc3cc 2020-10-14T15:05:11 threadstate: rename tlsdata when building w/o threads
Edward Thomson 20450cbe 2020-10-14T13:44:59 Merge pull request #5546 from libgit2/ethomson/init Refactor "global" state
Edward Thomson e9858645 2020-10-14T12:40:20 Merge pull request #5661 from lhchavez/windows-leak-detection-deflake Make the Windows leak detection more robust
lhchavez fa3daa82 2020-10-13T08:02:59 Define `git___load` when building with `-DTHREADSAFE=OFF` This should allow folks that build in non-thread-safe environments to still be able to build the library. Fixes: #5663
lhchavez 4a0dceeb 2020-10-11T17:53:10 Make the Windows leak detection more robust This change: * Increases MY_ROW_LIMIT to 2M, since it has been failing in #5595's tests since it's _super_ close to the limit. * Calls `git_repository_free()` on a `git_repository` that was being leaked only in Windows. * Marks the global `git_repository` on `tests/repo/init.c` as `NULL` after being freed to make any accidental access more noisy. * Uses `cl_assert_equal_i()` in `test_trace_windows_stacktrace__leaks` to make the test failures more actionable. * Renames the globals in `tests/repo/init.c` so that they don't start with an underscore.
Edward Thomson 634c285a 2020-07-11T12:35:58 Move libgit2 settings into libgit2.c
Edward Thomson 1ec4702a 2020-07-11T12:25:51 Rename global.c to libgit2.c Now that we've identified that our global settings really aren't global at all, and refactored the library to match that, change global.c to libgit2.c, which is especially nice since the prefix of the functions matches the filename.
Edward Thomson e316b0d3 2020-05-15T11:47:09 runtime: move init/shutdown into the "runtime" Provide a mechanism for system components to register for initialization and shutdown of the libgit2 runtime.
Edward Thomson 8970acb7 2020-05-15T10:29:41 thread: don't use the global tlsdata for thread exit We want to store a pointer to emulate `pthread_exit` on Windows. Do this within the threading infrastructure so that it could potentially be re-used outside of the context of libgit2 itself.
Edward Thomson 4853d94c 2020-05-14T10:36:35 global: separate global state from thread-local state Our "global initialization" has accumulated some debris over the years. It was previously responsible for both running the various global initializers (that set up various subsystems) _and_ setting up the "global state", which is actually the thread-local state for things like error reporting. Separate the thread local state out into "threadstate". Use the normal subsystem initialization functions that we already have to set it up. This makes both the global initialization system and the threadstate system simpler to reason about.
Edward Thomson bc3919ab 2020-07-11T12:14:26 global init: check error message buffer allocation Ensure that we can allocate the error message buffer. In keeping with our typical policiess, we allow (small) memory leaks in the case where we're out of memory.
Edward Thomson 8aa69f88 2020-05-13T10:48:13 mwindow: localize mutex Move the mwindow mutex into the mwindow code itself, initializing it in the mwindow global initialization function instead of in the global initializer.
Edward Thomson 6554b40e 2020-05-13T10:39:33 settings: localize global data Move the settings global data teardown into its own separate function, instead of intermingled with the global state.
Edward Thomson 521aa8c1 2020-05-12T13:21:26 win32: teach the allocator to deal with crtdbg Move the MSVC C runtime debugging bits into the allocator's global init function.
Edward Thomson fe12423a 2020-05-12T13:08:22 init: move thread init to git_global_threads_init Instead of treating win32 thread initialization specially in the win32 git_libgit2_init function, add a git_global_threads_init function.
Edward Thomson 94e34582 2020-10-11T11:32:04 Merge pull request #5651 from libgit2/ethomson/clone_branch clone: update origin's HEAD
lhchavez 03c0938f 2020-08-25T06:13:38 Avoid using atomics in pool.c Instead, globally initialize the system page size.
lhchavez cc1d7f5c 2020-08-01T17:47:20 Improve the support of atomics This change: * Starts using GCC's and clang's `__atomic_*` intrinsics instead of the `__sync_*` ones, since the former supercede the latter (and can be safely replaced by their equivalent `__atomic_*` version with the sequentially consistent model). * Makes `git_atomic64`'s value `volatile`. Otherwise, this will make ThreadSanitizer complain. * Adds ways to load the values from atomics. As it turns out, unsynchronized read are okay only in some architectures, but if we want to be correct (and make ThreadSanitizer happy), those loads should also be performed with the atomic builtins. * Fixes two ThreadSanitizer warnings, as a proof-of-concept that this works: - Avoid directly accessing `git_refcount`'s `owner` directly, and instead makes all callers go through the `GIT_REFCOUNT_*()` macros, which also use the atomic utilities. - Makes `pool_system_page_size()` race-free. Part of: #5592
Eric Huss 5b7e7131 2020-10-07T15:54:08 Fix error return for invalid extensions.
Dan Tull cce966c3 2020-10-06T17:51:14 Change bare free to allocator free. The info pointer was allocated with git__malloc, so needs to be free'd with git__free. This bug can lurk pretty easily since if there's no custom allocator this is fine.
Edward Thomson c1f1bcad 2020-10-05T11:04:38 clone: update origin's HEAD Update `refs/remotes/origin/HEAD` as a symbolic link to the remote's default branch.