<feed xmlns='http://www.w3.org/2005/Atom'>
<title>delta/libgit2.git/include/git2/errors.h, branch ethomson/index_iterator</title>
<subtitle>github.com: libgit2/libgit2.git
</subtitle>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/libgit2.git/'/>
<entry>
<title>apply: return a specific exit code on failure</title>
<updated>2018-11-04T09:21:48+00:00</updated>
<author>
<name>Edward Thomson</name>
<email>ethomson@edwardthomson.com</email>
</author>
<published>2018-06-25T12:24:49+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/libgit2.git/commit/?id=c3077ea0fa5ea8e0b27b1b47e95032da0591d861'/>
<id>c3077ea0fa5ea8e0b27b1b47e95032da0591d861</id>
<content type='text'>
Return `GIT_EAPPLYFAIL` on patch application failure so that users can
determine that patch application failed due to a malformed/conflicting
patch by looking at the error code.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Return `GIT_EAPPLYFAIL` on patch application failure so that users can
determine that patch application failed due to a malformed/conflicting
patch by looking at the error code.
</pre>
</div>
</content>
</entry>
<entry>
<title>Merge pull request #4788 from tiennou/doc-fixes</title>
<updated>2018-08-30T10:51:05+00:00</updated>
<author>
<name>Patrick Steinhardt</name>
<email>ps@pks.im</email>
</author>
<published>2018-08-30T10:51:05+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/libgit2.git/commit/?id=7edc1c870e34647a5fad0f243331d0385b2cab5d'/>
<id>7edc1c870e34647a5fad0f243331d0385b2cab5d</id>
<content type='text'>
Documentation fixes</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Documentation fixes</pre>
</div>
</content>
</entry>
<entry>
<title>doc: fix comment on GIT_EUSER</title>
<updated>2018-08-29T19:56:26+00:00</updated>
<author>
<name>Etienne Samson</name>
<email>samson.etienne@gmail.com</email>
</author>
<published>2018-08-29T19:56:26+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/libgit2.git/commit/?id=7765c0a9ff4f77fd979a0a134bdfc71a1010dafb'/>
<id>7765c0a9ff4f77fd979a0a134bdfc71a1010dafb</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Add two words to clarify</title>
<updated>2018-08-27T07:23:02+00:00</updated>
<author>
<name>Johan Abildskov</name>
<email>randomsort@gmail.com</email>
</author>
<published>2018-08-27T07:23:02+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/libgit2.git/commit/?id=c0b2e5256ca3580b8c0fd2e6b04ae1c27d692e2e'/>
<id>c0b2e5256ca3580b8c0fd2e6b04ae1c27d692e2e</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Update giterr_last API documentation to reflect real behaviour</title>
<updated>2018-08-20T11:51:28+00:00</updated>
<author>
<name>Johan Abildskov</name>
<email>randomsort@gmail.com</email>
</author>
<published>2018-08-20T11:51:28+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/libgit2.git/commit/?id=4bd2a508fbb100052b42a5aa35d829514d69a0fb'/>
<id>4bd2a508fbb100052b42a5aa35d829514d69a0fb</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>index: return a unique error code on dirty index</title>
<updated>2018-06-29T13:54:28+00:00</updated>
<author>
<name>Edward Thomson</name>
<email>ethomson@edwardthomson.com</email>
</author>
<published>2018-06-22T10:07:54+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/libgit2.git/commit/?id=787768c2d70dfcd1c9ebc1854b5d0f67d2e6d4d9'/>
<id>787768c2d70dfcd1c9ebc1854b5d0f67d2e6d4d9</id>
<content type='text'>
When the index is dirty, return GIT_EINDEXDIRTY so that consumers can
identify the exact problem programatically.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
When the index is dirty, return GIT_EINDEXDIRTY so that consumers can
identify the exact problem programatically.
</pre>
</div>
</content>
</entry>
<entry>
<title>odb: verify object hashes</title>
<updated>2017-04-28T12:05:45+00:00</updated>
<author>
<name>Patrick Steinhardt</name>
<email>ps@pks.im</email>
</author>
<published>2017-04-10T07:30:08+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/libgit2.git/commit/?id=28a0741f1ae6f5e1261c8e73854dda69e7a61067'/>
<id>28a0741f1ae6f5e1261c8e73854dda69e7a61067</id>
<content type='text'>
The upstream git.git project verifies objects when looking them up from
disk. This avoids scenarios where objects have somehow become corrupt on
disk, e.g. due to hardware failures or bit flips. While our mantra is
usually to follow upstream behavior, we do not do so in this case, as we
never check hashes of objects we have just read from disk.

To fix this, we create a new error class `GIT_EMISMATCH` which denotes
that we have looked up an object with a hashsum mismatch. `odb_read_1`
will then, after having read the object from its backend, hash the
object and compare the resulting hash to the expected hash. If hashes do
not match, it will return an error.

This obviously introduces another computation of checksums and could
potentially impact performance. Note though that we usually perform I/O
operations directly before doing this computation, and as such the
actual overhead should be drowned out by I/O. Running our test suite
seems to confirm this guess. On a Linux system with best-of-five
timings, we had 21.592s with the check enabled and 21.590s with the
ckeck disabled. Note though that our test suite mostly contains very
small blobs only. It is expected that repositories with bigger blobs may
notice an increased hit by this check.

In addition to a new test, we also had to change the
odb::backend::nonrefreshing test suite, which now triggers a hashsum
mismatch when looking up the commit "deadbeef...". This is expected, as
the fake backend allocated inside of the test will return an empty
object for the OID "deadbeef...", which will obviously not hash back to
"deadbeef..." again. We can simply adjust the hash to equal the hash of
the empty object here to fix this test.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The upstream git.git project verifies objects when looking them up from
disk. This avoids scenarios where objects have somehow become corrupt on
disk, e.g. due to hardware failures or bit flips. While our mantra is
usually to follow upstream behavior, we do not do so in this case, as we
never check hashes of objects we have just read from disk.

To fix this, we create a new error class `GIT_EMISMATCH` which denotes
that we have looked up an object with a hashsum mismatch. `odb_read_1`
will then, after having read the object from its backend, hash the
object and compare the resulting hash to the expected hash. If hashes do
not match, it will return an error.

This obviously introduces another computation of checksums and could
potentially impact performance. Note though that we usually perform I/O
operations directly before doing this computation, and as such the
actual overhead should be drowned out by I/O. Running our test suite
seems to confirm this guess. On a Linux system with best-of-five
timings, we had 21.592s with the check enabled and 21.590s with the
ckeck disabled. Note though that our test suite mostly contains very
small blobs only. It is expected that repositories with bigger blobs may
notice an increased hit by this check.

In addition to a new test, we also had to change the
odb::backend::nonrefreshing test suite, which now triggers a hashsum
mismatch when looking up the commit "deadbeef...". This is expected, as
the fake backend allocated inside of the test will return an empty
object for the OID "deadbeef...", which will obviously not hash back to
"deadbeef..." again. We can simply adjust the hash to equal the hash of
the empty object here to fix this test.
</pre>
</div>
</content>
</entry>
<entry>
<title>win32: introduce `do_with_retries` macro</title>
<updated>2017-04-01T09:47:30+00:00</updated>
<author>
<name>Edward Thomson</name>
<email>ethomson@edwardthomson.com</email>
</author>
<published>2017-04-01T09:44:17+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/libgit2.git/commit/?id=cc8d9a29e7cb24a43a10ec86a789efcf12394974'/>
<id>cc8d9a29e7cb24a43a10ec86a789efcf12394974</id>
<content type='text'>
Provide a macro that will allow us to run a function with posix-like
return values multiple times in a retry loop, with an optional cleanup
function called between invocations.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Provide a macro that will allow us to run a function with posix-like
return values multiple times in a retry loop, with an optional cleanup
function called between invocations.
</pre>
</div>
</content>
</entry>
<entry>
<title>hash: include sha1collisiondetection</title>
<updated>2017-03-03T10:50:27+00:00</updated>
<author>
<name>Edward Thomson</name>
<email>ethomson@github.com</email>
</author>
<published>2017-02-24T13:34:01+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/libgit2.git/commit/?id=2dfd1294f7a694bfa9e864a9489ae3cb318a5ed0'/>
<id>2dfd1294f7a694bfa9e864a9489ae3cb318a5ed0</id>
<content type='text'>
Include the SHA1 collision attack detection library from
https://github.com/cr-marcstevens/sha1collisiondetection
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Include the SHA1 collision attack detection library from
https://github.com/cr-marcstevens/sha1collisiondetection
</pre>
</div>
</content>
</entry>
<entry>
<title>worktree: implement `git_worktree_validate`</title>
<updated>2017-02-13T09:59:16+00:00</updated>
<author>
<name>Patrick Steinhardt</name>
<email>ps@pks.im</email>
</author>
<published>2015-10-21T11:49:55+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/libgit2.git/commit/?id=372dc9ff6ada409204b7c3de882e5dad16f30b36'/>
<id>372dc9ff6ada409204b7c3de882e5dad16f30b36</id>
<content type='text'>
Add a new function that checks wether a given `struct
git_worktree` is valid. The validation includes checking if the
gitdir, parent directory and common directory are present.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Add a new function that checks wether a given `struct
git_worktree` is valid. The validation includes checking if the
gitdir, parent directory and common directory are present.
</pre>
</div>
</content>
</entry>
</feed>
