1. 27 Jul, 2012 1 commit
  2. 26 Jul, 2012 5 commits
  3. 24 Jul, 2012 1 commit
  4. 21 Jul, 2012 1 commit
  5. 07 Jun, 2012 1 commit
  6. 04 Jun, 2012 1 commit
  7. 29 May, 2012 1 commit
  8. 26 May, 2012 1 commit
  9. 17 May, 2012 3 commits
  10. 09 May, 2012 2 commits
  11. 08 May, 2012 4 commits
  12. 01 May, 2012 1 commit
    • remote: don't free transport on disconnect · 42ea35c0
      Currently, git_remote_disconnect not only closes the connection but also
      frees the underlying transport object, making it impossible to write
      code like
      
      	// fetch stuff
      	git_remote_download()
      
      	// close connection
      	git_remote_disconnect()
      
      	// call user provided callback for each ref
      	git_remote_update_tips(remote, callback)
      
      because remote->refs points to references owned by the transport object.
      This means, we have an idling connection while running the callback for
      each reference.
      
      Instead, allow immediate disconnect and free the transport later in
      git_remote_free().
      Michael Schubert committed
  13. 25 Apr, 2012 3 commits
    • Implement git_pool paged memory allocator · 2bc8fa02
      This adds a `git_pool` object that can do simple paged memory
      allocation with free for the entire pool at once.  Using this,
      you can replace many small allocations with large blocks that
      can then cheaply be doled out in small pieces.  This is best
      used when you plan to free the small blocks all at once - for
      example, if they represent the parsed state from a file or data
      stream that are either all kept or all discarded.
      
      There are two real patterns of usage for `git_pools`: either
      for "string" allocation, where the item size is a single byte
      and you end up just packing the allocations in together, or for
      "fixed size" allocation where you are allocating a large object
      (e.g. a `git_oid`) and you generally just allocation single
      objects that can be tightly packed.  Of course, you can use it
      for other things, but those two cases are the easiest.
      Russell Belfer committed
    • remote: run a callback when updating the branch tips · f184836b
      This allows the caller to update an internal structure or update the
      user output with the tips that were updated.
      
      While in the area, only try to update the ref if the value is
      different from its old one.
      Carlos Martín Nieto committed
    • fetch: use the streaming indexer when downloading a pack · 7a520f5d
      This changes the git_remote_download() API, but the existing one is
      silly, so you don't get to complain.
      
      The new API allows to know how much data has been downloaded, how many
      objects we expect in total and how many we've processed.
      Carlos Martín Nieto committed
  14. 11 Apr, 2012 1 commit
  15. 02 Mar, 2012 1 commit
    • Clean up GIT_UNUSED macros on all platforms · 854eccbb
      It turns out that commit 31e9cfc4cbcaf1b38cdd3dbe3282a8f57e5366a5
      did not fix the GIT_USUSED behavior on all platforms.  This commit
      walks through and really cleans things up more thoroughly, getting
      rid of the unnecessary stuff.
      
      To remove the use of some GIT_UNUSED, I ended up adding a couple
      of new iterators for hashtables that allow you to iterator just
      over keys or just over values.
      
      In making this change, I found a bug in the clar tests (where we
      were doing *count++ but meant to do (*count)++ to increment the
      value).  I fixed that but then found the test failing because it
      was not really using an empty repo.  So, I took some of the code
      that I wrote for iterator testing and moved it to clar_helpers.c,
      then made use of that to make it easier to open fixtures on a
      per test basis even within a single test file.
      Russell Belfer committed
  16. 26 Feb, 2012 1 commit
  17. 24 Feb, 2012 1 commit
  18. 21 Feb, 2012 1 commit
  19. 20 Feb, 2012 3 commits
  20. 13 Feb, 2012 1 commit
  21. 19 Jan, 2012 1 commit
  22. 08 Dec, 2011 1 commit
    • Use git_buf for path storage instead of stack-based buffers · 97769280
      This converts virtually all of the places that allocate GIT_PATH_MAX
      buffers on the stack for manipulating paths to use git_buf objects
      instead.  The patch is pretty careful not to touch the public API
      for libgit2, so there are a few places that still use GIT_PATH_MAX.
      
      This extends and changes some details of the git_buf implementation
      to add a couple of extra functions and to make error handling easier.
      
      This includes serious alterations to all the path.c functions, and
      several of the fileops.c ones, too.  Also, there are a number of new
      functions that parallel existing ones except that use a git_buf
      instead of a stack-based buffer (such as git_config_find_global_r
      that exists alongsize git_config_find_global).
      
      This also modifies the win32 version of p_realpath to allocate whatever
      buffer size is needed to accommodate the realpath instead of hardcoding
      a GIT_PATH_MAX limit, but that change needs to be tested still.
      Russell Belfer committed
  23. 28 Nov, 2011 2 commits
  24. 26 Nov, 2011 1 commit
    • repository: Change ownership semantics · 9462c471
      The ownership semantics have been changed all over the library to be
      consistent. There are no more "borrowed" or duplicated references.
      
      Main changes:
      
      	- `git_repository_open2` and `3` have been dropped.
      
      	- Added setters and getters to hotswap all the repository owned
      	objects:
      
      		`git_repository_index`
      		`git_repository_set_index`
      		`git_repository_odb`
      		`git_repository_set_odb`
      		`git_repository_config`
      		`git_repository_set_config`
      		`git_repository_workdir`
      		`git_repository_set_workdir`
      
      	Now working directories/index files/ODBs and so on can be
      	hot-swapped after creating a repository and between operations.
      
      	- All these objects now have proper ownership semantics with
      	refcounting: they all require freeing after they are no longer
      	needed (the repository always keeps its internal reference).
      
      	- Repository open and initialization has been updated to keep in
      	mind the configuration files. Bare repositories are now always
      	detected, and a default config file is created on init.
      
      	- All the tests affected by these changes have been dropped from the
      	old test suite and ported to the new one.
      Vicent Marti committed
  25. 22 Nov, 2011 1 commit