<feed xmlns='http://www.w3.org/2005/Atom'>
<title>delta/libgit2.git/src, branch ethomson/http</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>httpclient: clear the read_buf on new requests</title>
<updated>2020-06-01T23:01:16+00:00</updated>
<author>
<name>Edward Thomson</name>
<email>ethomson@edwardthomson.com</email>
</author>
<published>2020-06-01T21:44:14+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/libgit2.git/commit/?id=04c7bdb42e4e8b374d5880358c7911236795fbcb'/>
<id>04c7bdb42e4e8b374d5880358c7911236795fbcb</id>
<content type='text'>
The httpclient implementation keeps a `read_buf` that holds the data
in the body of the response after the headers have been written.  We
store that data for subsequent calls to `git_http_client_read_body`.  If
we want to stop reading body data and send another request, we need to
clear that cached data.

Clear the cached body data on new requests, just like we read any
outstanding data from the socket.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The httpclient implementation keeps a `read_buf` that holds the data
in the body of the response after the headers have been written.  We
store that data for subsequent calls to `git_http_client_read_body`.  If
we want to stop reading body data and send another request, we need to
clear that cached data.

Clear the cached body data on new requests, just like we read any
outstanding data from the socket.
</pre>
</div>
</content>
</entry>
<entry>
<title>httpclient: don't read more than the client wants</title>
<updated>2020-06-01T22:56:18+00:00</updated>
<author>
<name>Edward Thomson</name>
<email>ethomson@edwardthomson.com</email>
</author>
<published>2020-06-01T22:53:55+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/libgit2.git/commit/?id=aa8b2c0f6068454d30e9b0f20f424311337a37f1'/>
<id>aa8b2c0f6068454d30e9b0f20f424311337a37f1</id>
<content type='text'>
When `git_http_client_read_body` is invoked, it provides the size of the
buffer that can be read into.  This will be set as the parser context's
`output_size` member.  Use this as an upper limit on our reads, and
ensure that we do not read more than the client requests.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
When `git_http_client_read_body` is invoked, it provides the size of the
buffer that can be read into.  This will be set as the parser context's
`output_size` member.  Use this as an upper limit on our reads, and
ensure that we do not read more than the client requests.
</pre>
</div>
</content>
</entry>
<entry>
<title>httpclient: read_body should return 0 at EOF</title>
<updated>2020-06-01T21:15:17+00:00</updated>
<author>
<name>Edward Thomson</name>
<email>ethomson@edwardthomson.com</email>
</author>
<published>2020-06-01T18:10:38+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/libgit2.git/commit/?id=570f0340f06f49b06ff536463cec8a2e2411b948'/>
<id>570f0340f06f49b06ff536463cec8a2e2411b948</id>
<content type='text'>
When users call `git_http_client_read_body`, it should return 0 at the
end of a message.  When the `on_message_complete` callback is called,
this will set `client-&gt;state` to `DONE`.  In our read loop, we look for
this condition and exit.

Without this, when there is no data left except the end of message chunk
(`0\r\n`) in the http stream, we would block by reading the three bytes
off the stream but not making progress in any `on_body` callbacks.
Listening to the `on_message_complete` callback allows us to stop trying
to read from the socket when we've read the end of message chunk.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
When users call `git_http_client_read_body`, it should return 0 at the
end of a message.  When the `on_message_complete` callback is called,
this will set `client-&gt;state` to `DONE`.  In our read loop, we look for
this condition and exit.

Without this, when there is no data left except the end of message chunk
(`0\r\n`) in the http stream, we would block by reading the three bytes
off the stream but not making progress in any `on_body` callbacks.
Listening to the `on_message_complete` callback allows us to stop trying
to read from the socket when we've read the end of message chunk.
</pre>
</div>
</content>
</entry>
<entry>
<title>Merge pull request #5526 from libgit2/ethomson/poolinit</title>
<updated>2020-06-01T13:05:51+00:00</updated>
<author>
<name>Patrick Steinhardt</name>
<email>ps@pks.im</email>
</author>
<published>2020-06-01T13:05:51+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/libgit2.git/commit/?id=17641f1f82ce6e6d2a52952a896525572c7fc7da'/>
<id>17641f1f82ce6e6d2a52952a896525572c7fc7da</id>
<content type='text'>
git_pool_init: allow the function to fail</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
git_pool_init: allow the function to fail</pre>
</div>
</content>
</entry>
<entry>
<title>git_pool_init: handle failure cases</title>
<updated>2020-06-01T12:12:17+00:00</updated>
<author>
<name>Edward Thomson</name>
<email>ethomson@edwardthomson.com</email>
</author>
<published>2020-05-23T09:15:51+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/libgit2.git/commit/?id=0f35efeb5722f950218e3649d7814a6a91b1c351'/>
<id>0f35efeb5722f950218e3649d7814a6a91b1c351</id>
<content type='text'>
Propagate failures caused by pool initialization errors.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Propagate failures caused by pool initialization errors.
</pre>
</div>
</content>
</entry>
<entry>
<title>Merge pull request #5527 from libgit2/ethomson/config_unreadable</title>
<updated>2020-06-01T11:57:12+00:00</updated>
<author>
<name>Patrick Steinhardt</name>
<email>ps@pks.im</email>
</author>
<published>2020-06-01T11:57:12+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/libgit2.git/commit/?id=1bbdf15d30e70d4068cb2b520cf3adfc25135a4d'/>
<id>1bbdf15d30e70d4068cb2b520cf3adfc25135a4d</id>
<content type='text'>
Handle unreadable configuration files</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Handle unreadable configuration files</pre>
</div>
</content>
</entry>
<entry>
<title>config: ignore unreadable configuration files</title>
<updated>2020-06-01T11:21:29+00:00</updated>
<author>
<name>Wil Shipley</name>
<email>wjs@delicious-monster.com</email>
</author>
<published>2020-05-07T02:57:07+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/libgit2.git/commit/?id=d1409f48e3e9c1d1494a4c02979ca381eb2298cf'/>
<id>d1409f48e3e9c1d1494a4c02979ca381eb2298cf</id>
<content type='text'>
Modified `config_file_open()` so it returns 0 if the config file is
not readable, which happens on global config files under macOS
sandboxing (note that for some reason `access(F_OK)` DOES work with
sandboxing, but it is lying). Without this read check sandboxed
applications on macOS can not open any repository, because
`config_file_read()` will return GIT_ERROR when it cannot read the
global /Users/username/.gitconfig file, and the upper layers will
just completely abort on GIT_ERROR when attempting to load the
global config file, so no repositories can be opened.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Modified `config_file_open()` so it returns 0 if the config file is
not readable, which happens on global config files under macOS
sandboxing (note that for some reason `access(F_OK)` DOES work with
sandboxing, but it is lying). Without this read check sandboxed
applications on macOS can not open any repository, because
`config_file_read()` will return GIT_ERROR when it cannot read the
global /Users/username/.gitconfig file, and the upper layers will
just completely abort on GIT_ERROR when attempting to load the
global config file, so no repositories can be opened.
</pre>
</div>
</content>
</entry>
<entry>
<title>index: write v4: bugfix: prefix path with strip_len, not same_len</title>
<updated>2020-05-25T21:36:17+00:00</updated>
<author>
<name>Patrick Wang</name>
<email>mail6543210@yahoo.com.tw</email>
</author>
<published>2020-05-25T20:53:09+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/libgit2.git/commit/?id=8c96d56dd0af7e7186a93915c33eda6758a9da3c'/>
<id>8c96d56dd0af7e7186a93915c33eda6758a9da3c</id>
<content type='text'>
According to index-format.txt of git, the path of an entry is prefixed
with N, where N indicates the length of bytes to be stripped.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
According to index-format.txt of git, the path of an entry is prefixed
with N, where N indicates the length of bytes to be stripped.
</pre>
</div>
</content>
</entry>
<entry>
<title>Merge pull request #5522 from pks-t/pks/openssl-cert-memleak</title>
<updated>2020-05-23T10:02:07+00:00</updated>
<author>
<name>Edward Thomson</name>
<email>ethomson@edwardthomson.com</email>
</author>
<published>2020-05-23T10:02:07+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/libgit2.git/commit/?id=27cb4e0ec193aa5430d1a32fd90b5dc2d86f5fe1'/>
<id>27cb4e0ec193aa5430d1a32fd90b5dc2d86f5fe1</id>
<content type='text'>
OpenSSL certificate memory leak</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
OpenSSL certificate memory leak</pre>
</div>
</content>
</entry>
<entry>
<title>git_pool_init: return an int</title>
<updated>2020-05-23T09:15:37+00:00</updated>
<author>
<name>Edward Thomson</name>
<email>ethomson@edwardthomson.com</email>
</author>
<published>2020-05-23T09:15:37+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/libgit2.git/commit/?id=abfdb8a6d252a4834df9234ad338c97f1a4f97f2'/>
<id>abfdb8a6d252a4834df9234ad338c97f1a4f97f2</id>
<content type='text'>
Let `git_pool_init` return an int so that it could fail.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Let `git_pool_init` return an int so that it could fail.
</pre>
</div>
</content>
</entry>
</feed>
