<feed xmlns='http://www.w3.org/2005/Atom'>
<title>delta/libgit2.git/src/buffer.c, branch cmn/error-buffer</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>buffer: make use of EINVALID for growing a borrowed buffer</title>
<updated>2015-06-24T21:49:10+00:00</updated>
<author>
<name>Carlos Martín Nieto</name>
<email>cmn@dwim.me</email>
</author>
<published>2015-06-24T17:32:56+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/libgit2.git/commit/?id=a65992355dac71490f4b22b3f2c0d55a1beca01b'/>
<id>a65992355dac71490f4b22b3f2c0d55a1beca01b</id>
<content type='text'>
This explains more closely what happens. While here, set an error
message.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This explains more closely what happens. While here, set an error
message.
</pre>
</div>
</content>
</entry>
<entry>
<title>buffer: don't allow growing borrowed buffers</title>
<updated>2015-06-24T21:49:10+00:00</updated>
<author>
<name>Carlos Martín Nieto</name>
<email>cmn@dwim.me</email>
</author>
<published>2015-06-23T13:41:58+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/libgit2.git/commit/?id=caab22c0d468e90b6a95072f3092d5dcf331b3ef'/>
<id>caab22c0d468e90b6a95072f3092d5dcf331b3ef</id>
<content type='text'>
When we don't own a buffer (asize=0) we currently allow the usage of
grow to copy the memory into a buffer we do own. This muddles the
meaning of grow, and lets us be a bit cavalier with ownership semantics.

Don't allow this any more. Usage of grow should be restricted to buffers
which we know own their own memory. If unsure, we must not attempt to
modify it.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
When we don't own a buffer (asize=0) we currently allow the usage of
grow to copy the memory into a buffer we do own. This muddles the
meaning of grow, and lets us be a bit cavalier with ownership semantics.

Don't allow this any more. Usage of grow should be restricted to buffers
which we know own their own memory. If unsure, we must not attempt to
modify it.
</pre>
</div>
</content>
</entry>
<entry>
<title>buffer: introduce git_buf_attach_notowned</title>
<updated>2015-02-19T15:05:33+00:00</updated>
<author>
<name>Edward Thomson</name>
<email>ethomson@microsoft.com</email>
</author>
<published>2015-02-19T15:05:33+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/libgit2.git/commit/?id=d4cf167515d3ed7b27c1358fc2e19b9caf66e8ad'/>
<id>d4cf167515d3ed7b27c1358fc2e19b9caf66e8ad</id>
<content type='text'>
Provide a convenience function that creates a buffer that can be provided
to callers but will not be freed via `git_buf_free`, so the buffer
creator maintains the allocation lifecycle of the buffer's contents.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Provide a convenience function that creates a buffer that can be provided
to callers but will not be freed via `git_buf_free`, so the buffer
creator maintains the allocation lifecycle of the buffer's contents.
</pre>
</div>
</content>
</entry>
<entry>
<title>Make our overflow check look more like gcc/clang's</title>
<updated>2015-02-13T14:27:33+00:00</updated>
<author>
<name>Edward Thomson</name>
<email>ethomson@microsoft.com</email>
</author>
<published>2015-02-12T17:19:37+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/libgit2.git/commit/?id=f1453c59b2afb9dab43281bfe9f1ba34cf6e0d02'/>
<id>f1453c59b2afb9dab43281bfe9f1ba34cf6e0d02</id>
<content type='text'>
Make our overflow checking look more like gcc and clang's, so that
we can substitute it out with the compiler instrinsics on platforms
that support it.  This means dropping the ability to pass `NULL` as
an out parameter.

As a result, the macros also get updated to reflect this as well.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Make our overflow checking look more like gcc and clang's, so that
we can substitute it out with the compiler instrinsics on platforms
that support it.  This means dropping the ability to pass `NULL` as
an out parameter.

As a result, the macros also get updated to reflect this as well.
</pre>
</div>
</content>
</entry>
<entry>
<title>overflow checking: don't make callers set oom</title>
<updated>2015-02-13T03:54:47+00:00</updated>
<author>
<name>Edward Thomson</name>
<email>ethomson@microsoft.com</email>
</author>
<published>2015-02-11T14:39:38+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/libgit2.git/commit/?id=2884cc42de8b20a58cec8488d014a853d47c047e'/>
<id>2884cc42de8b20a58cec8488d014a853d47c047e</id>
<content type='text'>
Have the ALLOC_OVERFLOW testing macros also simply set_oom in the
case where a computation would overflow, so that callers don't
need to.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Have the ALLOC_OVERFLOW testing macros also simply set_oom in the
case where a computation would overflow, so that callers don't
need to.
</pre>
</div>
</content>
</entry>
<entry>
<title>git_buf_grow_by: increase buf asize incrementally</title>
<updated>2015-02-13T03:54:47+00:00</updated>
<author>
<name>Edward Thomson</name>
<email>ethomson@microsoft.com</email>
</author>
<published>2015-02-11T04:55:07+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/libgit2.git/commit/?id=4aa664ae3953d99c2ae4cd769f02818bc122eebc'/>
<id>4aa664ae3953d99c2ae4cd769f02818bc122eebc</id>
<content type='text'>
Introduce `git_buf_grow_by` to incrementally increase the size of a
`git_buf`, performing an overflow calculation on the growth.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Introduce `git_buf_grow_by` to incrementally increase the size of a
`git_buf`, performing an overflow calculation on the growth.
</pre>
</div>
</content>
</entry>
<entry>
<title>allocations: test for overflow of requested size</title>
<updated>2015-02-13T03:54:46+00:00</updated>
<author>
<name>Edward Thomson</name>
<email>ethomson@microsoft.com</email>
</author>
<published>2015-02-10T04:41:13+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/libgit2.git/commit/?id=392702ee2c88d7d8aaff25f7a84acb73606f9094'/>
<id>392702ee2c88d7d8aaff25f7a84acb73606f9094</id>
<content type='text'>
Introduce some helper macros to test integer overflow from arithmetic
and set error message appropriately.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Introduce some helper macros to test integer overflow from arithmetic
and set error message appropriately.
</pre>
</div>
</content>
</entry>
<entry>
<title>Fix crash in free() when git_buf_grow() fails.</title>
<updated>2015-01-09T15:46:44+00:00</updated>
<author>
<name>Jeff Hostetler</name>
<email>jeffhost@microsoft.com</email>
</author>
<published>2015-01-08T22:24:12+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/libgit2.git/commit/?id=4b1018d24f980273528743c27c47ceb96cb720bd'/>
<id>4b1018d24f980273528743c27c47ceb96cb720bd</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>buffer: Do not `put` anything if len is 0</title>
<updated>2014-11-21T16:21:33+00:00</updated>
<author>
<name>Vicent Marti</name>
<email>tanoku@gmail.com</email>
</author>
<published>2014-11-21T12:31:30+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/libgit2.git/commit/?id=92e0b67930f350a40575954f4638cbc71fee57d2'/>
<id>92e0b67930f350a40575954f4638cbc71fee57d2</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Introduce git_buf_decode_base64</title>
<updated>2014-08-15T15:12:42+00:00</updated>
<author>
<name>Edward Thomson</name>
<email>ethomson@microsoft.com</email>
</author>
<published>2014-07-31T19:14:56+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/libgit2.git/commit/?id=e003f83a5840d6e9966f1830768771bcd205ba52'/>
<id>e003f83a5840d6e9966f1830768771bcd205ba52</id>
<content type='text'>
Decode base64-encoded text into a git_buf
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Decode base64-encoded text into a git_buf
</pre>
</div>
</content>
</entry>
</feed>
