<feed xmlns='http://www.w3.org/2005/Atom'>
<title>delta/libgit2.git/src/errors.c, branch attr-export</title>
<subtitle>github.com: libgit2/libgit2.git
</subtitle>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/libgit2.git/'/>
<entry>
<title>errors: Use a git_buf for building error strings</title>
<updated>2012-05-03T07:04:04+00:00</updated>
<author>
<name>Vicent Martí</name>
<email>tanoku@gmail.com</email>
</author>
<published>2012-05-03T07:04:04+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/libgit2.git/commit/?id=2277216613d974b5a9cd00be9120be194706ff11'/>
<id>2277216613d974b5a9cd00be9120be194706ff11</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Remove old and unused error codes</title>
<updated>2012-05-03T02:56:38+00:00</updated>
<author>
<name>Vicent Martí</name>
<email>tanoku@gmail.com</email>
</author>
<published>2012-05-03T02:56:38+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/libgit2.git/commit/?id=3fbcac89c47cb66ea193f66da6d93d1c36ed0f5e'/>
<id>3fbcac89c47cb66ea193f66da6d93d1c36ed0f5e</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Implement git_pool paged memory allocator</title>
<updated>2012-04-25T17:42:37+00:00</updated>
<author>
<name>Russell Belfer</name>
<email>rb@github.com</email>
</author>
<published>2012-04-17T17:14:24+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/libgit2.git/commit/?id=2bc8fa0227d549006a9870620ca1f2e08a0c305e'/>
<id>2bc8fa0227d549006a9870620ca1f2e08a0c305e</id>
<content type='text'>
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.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
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.
</pre>
</div>
</content>
</entry>
<entry>
<title>Refactor git_repository_open with new options</title>
<updated>2012-04-11T19:11:35+00:00</updated>
<author>
<name>Russell Belfer</name>
<email>rb@github.com</email>
</author>
<published>2012-04-11T18:52:59+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/libgit2.git/commit/?id=7784bcbbee972d1f00ea88655a5592fb44ca767d'/>
<id>7784bcbbee972d1f00ea88655a5592fb44ca767d</id>
<content type='text'>
Add a new command `git_repository_open_ext` with extended options
that control how searching for a repository will be done.  The
existing `git_repository_open` and `git_repository_discover` are
reimplemented on top of it.  We may want to change the default
behavior of `git_repository_open` but this commit does not do that.

Improve support for "gitdir" files where the work dir is separate
from the repo and support for the "separate-git-dir" config.  Also,
add support for opening repos created with `git-new-workdir` script
(although I have only confirmed that they can be opened, not that
all functions work correctly).

There are also a few minor changes that came up:

- Fix `git_path_prettify` to allow in-place prettifying.

- Fix `git_path_root` to support backslashes on Win32.  This fix
  should help many repo open/discover scenarios - it is the one
  function called when opening before prettifying the path.

- Tweak `git_config_get_string` to set the "out" pointer to NULL
  if the config value is not found.  Allows some other cleanup.

- Fix a couple places that should have been calling
  `git_repository_config__weakptr` and were not.

- Fix `cl_git_sandbox_init` clar helper to support bare repos.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Add a new command `git_repository_open_ext` with extended options
that control how searching for a repository will be done.  The
existing `git_repository_open` and `git_repository_discover` are
reimplemented on top of it.  We may want to change the default
behavior of `git_repository_open` but this commit does not do that.

Improve support for "gitdir" files where the work dir is separate
from the repo and support for the "separate-git-dir" config.  Also,
add support for opening repos created with `git-new-workdir` script
(although I have only confirmed that they can be opened, not that
all functions work correctly).

There are also a few minor changes that came up:

- Fix `git_path_prettify` to allow in-place prettifying.

- Fix `git_path_root` to support backslashes on Win32.  This fix
  should help many repo open/discover scenarios - it is the one
  function called when opening before prettifying the path.

- Tweak `git_config_get_string` to set the "out" pointer to NULL
  if the config value is not found.  Allows some other cleanup.

- Fix a couple places that should have been calling
  `git_repository_config__weakptr` and were not.

- Fix `cl_git_sandbox_init` clar helper to support bare repos.
</pre>
</div>
</content>
</entry>
<entry>
<title>Resolve comments from pull request</title>
<updated>2012-03-13T21:23:24+00:00</updated>
<author>
<name>Russell Belfer</name>
<email>arrbee@arrbee.com</email>
</author>
<published>2012-03-13T21:23:24+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/libgit2.git/commit/?id=e3c475107045cb89c53c114716bafebc7538433f'/>
<id>e3c475107045cb89c53c114716bafebc7538433f</id>
<content type='text'>
This converts the map validation function into a macro, tweaks
the GITERR_OS system error automatic appending, and adds a
tentative new error access API and some quick unit tests for
both the old and new error APIs.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This converts the map validation function into a macro, tweaks
the GITERR_OS system error automatic appending, and adds a
tentative new error access API and some quick unit tests for
both the old and new error APIs.
</pre>
</div>
</content>
</entry>
<entry>
<title>Migrate ODB files to new error handling</title>
<updated>2012-03-13T05:55:40+00:00</updated>
<author>
<name>Russell Belfer</name>
<email>arrbee@arrbee.com</email>
</author>
<published>2012-03-13T05:55:40+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/libgit2.git/commit/?id=e1de726c15937a8dbf81d12ef0c872cf6576ebd0'/>
<id>e1de726c15937a8dbf81d12ef0c872cf6576ebd0</id>
<content type='text'>
This migrates odb.c, odb_loose.c, odb_pack.c and pack.c to
the new style of error handling.  Also got the unix and win32
versions of map.c.  There are some minor changes to other
files but no others were completely converted.

This also contains an update to filebuf so that a zeroed out
filebuf will not think that the fd (== 0) is actually open
(and inadvertently call close() on fd 0 if cleaned up).

Lastly, this was built and tested on win32 and contains a
bunch of fixes for the win32 build which was pretty broken.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This migrates odb.c, odb_loose.c, odb_pack.c and pack.c to
the new style of error handling.  Also got the unix and win32
versions of map.c.  There are some minor changes to other
files but no others were completely converted.

This also contains an update to filebuf so that a zeroed out
filebuf will not think that the fd (== 0) is actually open
(and inadvertently call close() on fd 0 if cleaned up).

Lastly, this was built and tested on win32 and contains a
bunch of fixes for the win32 build which was pretty broken.
</pre>
</div>
</content>
</entry>
<entry>
<title>error-handling: On-disk config file backend</title>
<updated>2012-03-09T19:09:22+00:00</updated>
<author>
<name>Vicent Martí</name>
<email>tanoku@gmail.com</email>
</author>
<published>2012-03-09T18:55:50+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/libgit2.git/commit/?id=dda708e78f3c3f43d814d46c29ab9f2b9d47ed5c'/>
<id>dda708e78f3c3f43d814d46c29ab9f2b9d47ed5c</id>
<content type='text'>
Includes:

	- Proper error reporting when encountering syntax errors in a
	config file (file, line number, column).

	- Rewritten `config_write`, now with 99% less goto-spaghetti

	- Error state in `git_filebuf`: filebuf write functions no longer
	need to be checked for error returns. If any of the writes performed
	on a buffer fail, the last call to `git_filebuf_commit` or
	`git_filebuf_hash` will fail accordingly and set the appropiate error
	message. Baller!
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Includes:

	- Proper error reporting when encountering syntax errors in a
	config file (file, line number, column).

	- Rewritten `config_write`, now with 99% less goto-spaghetti

	- Error state in `git_filebuf`: filebuf write functions no longer
	need to be checked for error returns. If any of the writes performed
	on a buffer fail, the last call to `git_filebuf_commit` or
	`git_filebuf_hash` will fail accordingly and set the appropiate error
	message. Baller!
</pre>
</div>
</content>
</entry>
<entry>
<title>Fix issues raised on pull request</title>
<updated>2012-03-07T18:52:17+00:00</updated>
<author>
<name>Russell Belfer</name>
<email>arrbee@arrbee.com</email>
</author>
<published>2012-03-07T18:52:17+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/libgit2.git/commit/?id=998f7b3dd76afbf462785a757b24a3554ad8534d'/>
<id>998f7b3dd76afbf462785a757b24a3554ad8534d</id>
<content type='text'>
This resolves the comments on pull request #590
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This resolves the comments on pull request #590
</pre>
</div>
</content>
</entry>
<entry>
<title>Migrating diff to new error handling</title>
<updated>2012-03-07T00:27:13+00:00</updated>
<author>
<name>Russell Belfer</name>
<email>arrbee@arrbee.com</email>
</author>
<published>2012-03-07T00:14:31+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/libgit2.git/commit/?id=ae9e29fde7e7d1c0c3e95bdabbb5c96fc71b1c71'/>
<id>ae9e29fde7e7d1c0c3e95bdabbb5c96fc71b1c71</id>
<content type='text'>
Ended up migrating a bunch of upstream functions as well
including vector, attr_file, and odb in order to get this
to work right.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Ended up migrating a bunch of upstream functions as well
including vector, attr_file, and odb in order to get this
to work right.
</pre>
</div>
</content>
</entry>
<entry>
<title>error-handling: References</title>
<updated>2012-03-05T23:43:10+00:00</updated>
<author>
<name>Vicent Martí</name>
<email>tanoku@gmail.com</email>
</author>
<published>2012-02-16T23:13:34+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/libgit2.git/commit/?id=1a48112342932e9fcd45a1ff5935f1c9c53b83d1'/>
<id>1a48112342932e9fcd45a1ff5935f1c9c53b83d1</id>
<content type='text'>
Yes, this is error handling solely for `refs.c`, but some of the
abstractions leak all ofer the code base.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Yes, this is error handling solely for `refs.c`, but some of the
abstractions leak all ofer the code base.
</pre>
</div>
</content>
</entry>
</feed>
