<feed xmlns='http://www.w3.org/2005/Atom'>
<title>git/strbuf.h, branch v2.3.3</title>
<subtitle>Mirror of https://git.kernel.org/pub/scm/git/git.git/
</subtitle>
<id>https://git.shady.money/git/atom?h=v2.3.3</id>
<link rel='self' href='https://git.shady.money/git/atom?h=v2.3.3'/>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/'/>
<updated>2014-09-19T18:38:39Z</updated>
<entry>
<title>Merge branch 'rs/export-strbuf-addchars'</title>
<updated>2014-09-19T18:38:39Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2014-09-19T18:38:39Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=56feed1c7641bbf7920efe6607c6a04309073baa'/>
<id>urn:sha1:56feed1c7641bbf7920efe6607c6a04309073baa</id>
<content type='text'>
Code clean-up.

* rs/export-strbuf-addchars:
  strbuf: use strbuf_addchars() for adding a char multiple times
  strbuf: export strbuf_addchars()
</content>
</entry>
<entry>
<title>strbuf: export strbuf_addchars()</title>
<updated>2014-09-08T18:26:45Z</updated>
<author>
<name>René Scharfe</name>
<email>l.s.r@web.de</email>
</author>
<published>2014-09-07T07:03:32Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=d07235a027e0c7ed2fee1aeb3bee8a858bf5ca58'/>
<id>urn:sha1:d07235a027e0c7ed2fee1aeb3bee8a858bf5ca58</id>
<content type='text'>
Move strbuf_addchars() to strbuf.c, where it belongs, and make it
available for other callers.

Signed-off-by: Rene Scharfe &lt;l.s.r@web.de&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>Merge branch 'rs/strbuf-getcwd'</title>
<updated>2014-09-02T20:28:44Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2014-09-02T20:27:45Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=f655651e09b9fa7bf8ff13f1b4a5b16c7956e4cf'/>
<id>urn:sha1:f655651e09b9fa7bf8ff13f1b4a5b16c7956e4cf</id>
<content type='text'>
Reduce the use of fixed sized buffer passed to getcwd() calls
by introducing xgetcwd() helper.

* rs/strbuf-getcwd:
  use strbuf_add_absolute_path() to add absolute paths
  abspath: convert absolute_path() to strbuf
  use xgetcwd() to set $GIT_DIR
  use xgetcwd() to get the current directory or die
  wrapper: add xgetcwd()
  abspath: convert real_path_internal() to strbuf
  abspath: use strbuf_getcwd() to remember original working directory
  setup: convert setup_git_directory_gently_1 et al. to strbuf
  unix-sockets: use strbuf_getcwd()
  strbuf: add strbuf_getcwd()
</content>
</entry>
<entry>
<title>abspath: convert absolute_path() to strbuf</title>
<updated>2014-08-26T18:06:06Z</updated>
<author>
<name>René Scharfe</name>
<email>l.s.r@web.de</email>
</author>
<published>2014-07-28T18:33:55Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=679eebe24d4c2120f8c01fb4524fcc489718fc9c'/>
<id>urn:sha1:679eebe24d4c2120f8c01fb4524fcc489718fc9c</id>
<content type='text'>
Move most of the code of absolute_path() into the new function
strbuf_add_absolute_path() and in the process transform it to use
struct strbuf and xgetcwd() instead of a PATH_MAX-sized buffer,
which can be too small on some file systems.

Signed-off-by: Rene Scharfe &lt;l.s.r@web.de&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>strbuf: add strbuf_getcwd()</title>
<updated>2014-07-28T20:48:07Z</updated>
<author>
<name>René Scharfe</name>
<email>l.s.r@web.de</email>
</author>
<published>2014-07-28T18:24:29Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=f22a76e9110e8e31efa3781b1a3cf2b4565d9e8a'/>
<id>urn:sha1:f22a76e9110e8e31efa3781b1a3cf2b4565d9e8a</id>
<content type='text'>
Add strbuf_getcwd(), which puts the current working directory into a
strbuf.  Because it doesn't use a fixed-size buffer it supports
arbitrarily long paths, provided the platform's getcwd() does as well.
At least on Linux and FreeBSD it handles paths longer than PATH_MAX
just fine.

Suggested-by: Karsten Blees &lt;karsten.blees@gmail.com&gt;
Helped-by: Duy Nguyen &lt;pclouds@gmail.com&gt;
Signed-off-by: Rene Scharfe &lt;l.s.r@web.de&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>Merge branch 'jk/strip-suffix'</title>
<updated>2014-07-16T18:26:00Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2014-07-16T18:25:59Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=6e4094731acee5207595a8416d19508107ea475d'/>
<id>urn:sha1:6e4094731acee5207595a8416d19508107ea475d</id>
<content type='text'>
* jk/strip-suffix:
  prepare_packed_git_one: refactor duplicate-pack check
  verify-pack: use strbuf_strip_suffix
  strbuf: implement strbuf_strip_suffix
  index-pack: use strip_suffix to avoid magic numbers
  use strip_suffix instead of ends_with in simple cases
  replace has_extension with ends_with
  implement ends_with via strip_suffix
  add strip_suffix function
  sha1_file: replace PATH_MAX buffer with strbuf in prepare_packed_git_one()
</content>
</entry>
<entry>
<title>strbuf: implement strbuf_strip_suffix</title>
<updated>2014-06-30T20:43:32Z</updated>
<author>
<name>Jeff King</name>
<email>peff@peff.net</email>
</author>
<published>2014-06-30T17:01:51Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=6dda4e60f2c3c309de6e3fe1b86a47846a86dabf'/>
<id>urn:sha1:6dda4e60f2c3c309de6e3fe1b86a47846a86dabf</id>
<content type='text'>
You can almost get away with just calling "strip_suffix_mem"
on a strbuf's buf and len fields. But we also need to move
the NUL-terminator to satisfy strbuf's invariants. Let's
provide a convenience wrapper that handles this.

Signed-off-by: Jeff King &lt;peff@peff.net&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>strbuf: add xstrfmt helper</title>
<updated>2014-06-19T19:25:17Z</updated>
<author>
<name>Jeff King</name>
<email>peff@peff.net</email>
</author>
<published>2014-06-18T20:01:34Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=30a0ddb705678d512185e359831479a6b3567147'/>
<id>urn:sha1:30a0ddb705678d512185e359831479a6b3567147</id>
<content type='text'>
You can use a strbuf to build up a string from parts, and
then detach it. In the general case, you might use multiple
strbuf_add* functions to do the building. However, in many
cases, a single strbuf_addf is sufficient, and we end up
with:

  struct strbuf buf = STRBUF_INIT;
  ...
  strbuf_addf(&amp;buf, fmt, some, args);
  str = strbuf_detach(&amp;buf, NULL);

We can make this much more readable (and avoid introducing
an extra variable, which can clutter the code) by
introducing a convenience function:

  str = xstrfmt(fmt, some, args);

Signed-off-by: Jeff King &lt;peff@peff.net&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>Merge branch 'jk/http-errors'</title>
<updated>2014-06-16T19:18:36Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2014-06-16T19:18:35Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=2075a0c27fa5cf4f9f03964d407dc015c1749a7e'/>
<id>urn:sha1:2075a0c27fa5cf4f9f03964d407dc015c1749a7e</id>
<content type='text'>
Propagate the error messages from the webserver better to the
client coming over the HTTP transport.

* jk/http-errors:
  http: default text charset to iso-8859-1
  remote-curl: reencode http error messages
  strbuf: add strbuf_reencode helper
  http: optionally extract charset parameter from content-type
  http: extract type/subtype portion of content-type
  t5550: test display of remote http error messages
  t/lib-httpd: use write_script to copy CGI scripts
  test-lib: preserve GIT_CURL_VERBOSE from the environment
</content>
</entry>
<entry>
<title>Merge branch 'jk/strbuf-tolower'</title>
<updated>2014-06-16T17:07:17Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2014-06-16T17:07:16Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=b4bba8de115b6aa48103443cc81a3be7111095a9'/>
<id>urn:sha1:b4bba8de115b6aa48103443cc81a3be7111095a9</id>
<content type='text'>
* jk/strbuf-tolower:
  strbuf: add strbuf_tolower function
</content>
</entry>
</feed>
