<feed xmlns='http://www.w3.org/2005/Atom'>
<title>user/sven/git.git/cache.h, branch v1.7.7.4</title>
<subtitle>Git
</subtitle>
<id>https://git.stealer.net/cgit.cgi/user/sven/git.git/atom?h=v1.7.7.4</id>
<link rel='self' href='https://git.stealer.net/cgit.cgi/user/sven/git.git/atom?h=v1.7.7.4'/>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/git.git/'/>
<updated>2011-10-06T20:54:32Z</updated>
<entry>
<title>attr: read core.attributesfile from git_default_core_config</title>
<updated>2011-10-06T20:54:32Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2011-10-06T18:22:24Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/git.git/commit/?id=64589a03a8ffb3eb4fb2ff8f416ff638a9aaa439'/>
<id>urn:sha1:64589a03a8ffb3eb4fb2ff8f416ff638a9aaa439</id>
<content type='text'>
This code calls git_config from a helper function to parse the config entry
it is interested in.  Calling git_config in this way may cause a problem if
the helper function can be called after a previous call to git_config by
another function since the second call to git_config may reset some
variable to the value in the config file which was previously overridden.

The above is not a problem in this case since the function passed to
git_config only parses one config entry and the variable it sets is not
assigned outside of the parsing function.  But a programmer who desires
all of the standard config options to be parsed may be tempted to modify
git_attr_config() so that it falls back to git_default_config() and then it
_would_ be vulnerable to the above described behavior.

So, move the call to git_config up into the top-level cmd_* function and
move the responsibility for parsing core.attributesfile into the main
config file parser.

Which is only the logical thing to do ;-)

Signed-off-by: Brandon Casey &lt;drafnel@gmail.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>Merge branch 'nd/maint-clone-gitdir'</title>
<updated>2011-08-29T04:20:28Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2011-08-29T04:20:28Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/git.git/commit/?id=2730f55527143d3476c159cebbdb63d5e6a5c2a8'/>
<id>urn:sha1:2730f55527143d3476c159cebbdb63d5e6a5c2a8</id>
<content type='text'>
* nd/maint-clone-gitdir:
  clone: allow to clone from .git file
  read_gitfile_gently(): rename misnamed function to read_gitfile()
</content>
</entry>
<entry>
<title>Merge branch 'cb/maint-ls-files-error-report'</title>
<updated>2011-08-23T22:34:31Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2011-08-23T22:34:31Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/git.git/commit/?id=6133e4da549efbda98565163705af0781b096a4c'/>
<id>urn:sha1:6133e4da549efbda98565163705af0781b096a4c</id>
<content type='text'>
* cb/maint-ls-files-error-report:
  ls-files: fix pathspec display on error
</content>
</entry>
<entry>
<title>read_gitfile_gently(): rename misnamed function to read_gitfile()</title>
<updated>2011-08-22T21:04:56Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2011-08-22T21:04:56Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/git.git/commit/?id=13d6ec913330ba90fb1a67ec5789e437f8ac4193'/>
<id>urn:sha1:13d6ec913330ba90fb1a67ec5789e437f8ac4193</id>
<content type='text'>
The function was not gentle at all to the callers and died without giving
them a chance to deal with possible errors. Rename it to read_gitfile(),
and update all the callers.

As no existing caller needs a true "gently" variant, we do not bother
adding one at this point.

Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>Merge branch 'js/ref-namespaces'</title>
<updated>2011-08-18T00:35:38Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2011-08-18T00:35:38Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/git.git/commit/?id=6ed547b53b90bebd2371b086b83b416b22b243b2'/>
<id>urn:sha1:6ed547b53b90bebd2371b086b83b416b22b243b2</id>
<content type='text'>
* js/ref-namespaces:
  ref namespaces: tests
  ref namespaces: documentation
  ref namespaces: Support remote repositories via upload-pack and receive-pack
  ref namespaces: infrastructure
  Fix prefix handling in ref iteration functions
</content>
</entry>
<entry>
<title>ls-files: fix pathspec display on error</title>
<updated>2011-08-11T20:04:16Z</updated>
<author>
<name>Clemens Buchacher</name>
<email>drizzd@aon.at</email>
</author>
<published>2011-08-01T21:19:58Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/git.git/commit/?id=0f64bfa9567f697d6152ef9ea937d4b573029a08'/>
<id>urn:sha1:0f64bfa9567f697d6152ef9ea937d4b573029a08</id>
<content type='text'>
The following sequence of commands reveals an issue with error
reporting of relative paths:

 $ mkdir sub
 $ cd sub
 $ git ls-files --error-unmatch ../bbbbb
 error: pathspec 'b' did not match any file(s) known to git.
 $ git commit --error-unmatch ../bbbbb
 error: pathspec 'b' did not match any file(s) known to git.

This bug is visible only if the normalized path (i.e., the relative
path from the repository root) is longer than the prefix.
Otherwise, the code skips over the normalized path and reads from
an unused memory location which still contains a leftover of the
original command line argument.

So instead, use the existing facilities to deal with relative paths
correctly.

Also fix inconsistency between "checkout" and "commit", e.g.

    $ cd Documentation
    $ git checkout nosuch.txt
    error: pathspec 'Documentation/nosuch.txt' did not match...
    $ git commit nosuch.txt
    error: pathspec 'nosuch.txt' did not match...

by propagating the prefix down the codepath that reports the error.

Signed-off-by: Clemens Buchacher &lt;drizzd@aon.at&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>Merge branch 'cb/partial-commit-relative-pathspec'</title>
<updated>2011-08-11T18:04:28Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2011-08-11T18:04:28Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/git.git/commit/?id=0af53e188a3a8915f65c3b3edaeed3e07d8d3802'/>
<id>urn:sha1:0af53e188a3a8915f65c3b3edaeed3e07d8d3802</id>
<content type='text'>
* cb/partial-commit-relative-pathspec:
  commit: allow partial commits with relative paths
</content>
</entry>
<entry>
<title>Merge branch 'jc/pack-order-tweak'</title>
<updated>2011-08-05T21:54:57Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2011-08-05T21:54:57Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/git.git/commit/?id=96790ca02935791b302cd65a4d092f4cdf5cd21e'/>
<id>urn:sha1:96790ca02935791b302cd65a4d092f4cdf5cd21e</id>
<content type='text'>
* jc/pack-order-tweak:
  pack-objects: optimize "recency order"
  core: log offset pack data accesses happened
</content>
</entry>
<entry>
<title>commit: allow partial commits with relative paths</title>
<updated>2011-08-02T21:20:35Z</updated>
<author>
<name>Clemens Buchacher</name>
<email>drizzd@aon.at</email>
</author>
<published>2011-07-30T17:13:47Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/git.git/commit/?id=8894d5358095a08c2f700a87ce9fdefb0b6eb61b'/>
<id>urn:sha1:8894d5358095a08c2f700a87ce9fdefb0b6eb61b</id>
<content type='text'>
In order to do partial commits, git-commit overlays a tree on the
cache and checks pathspecs against the result. Currently, the
overlaying is done using "prefix" which prevents relative pathspecs
with ".." and absolute pathspec from matching when they refer to
files not under "prefix" and absent from the index, but still in
the tree (i.e.  files staged for removal).

The point of providing a prefix at all is performance optimization.
If we say there is no common prefix for the files of interest, then
we have to read the entire tree into the index.

But even if we cannot use the working directory as a prefix, we can
still figure out if there is a common prefix for all given paths,
and use that instead. The pathspec_prefix() routine from ls-files.c
does exactly that.

Any use of global variables is removed from pathspec_prefix() so
that it can be called from commit.c.

Reported-by: Reuben Thomas &lt;rrt@sc3d.org&gt;
Analyzed-by: Michael J Gruber &lt;git@drmicha.warpmail.net&gt;
Signed-off-by: Clemens Buchacher &lt;drizzd@aon.at&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>Merge branch 'jc/index-pack'</title>
<updated>2011-07-19T16:54:51Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2011-07-19T16:54:51Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/git.git/commit/?id=d907bf8ef327cd47433d4a4bb0a1bb4e96b6e340'/>
<id>urn:sha1:d907bf8ef327cd47433d4a4bb0a1bb4e96b6e340</id>
<content type='text'>
* jc/index-pack:
  verify-pack: use index-pack --verify
  index-pack: show histogram when emulating "verify-pack -v"
  index-pack: start learning to emulate "verify-pack -v"
  index-pack: a miniscule refactor
  index-pack --verify: read anomalous offsets from v2 idx file
  write_idx_file: need_large_offset() helper function
  index-pack: --verify
  write_idx_file: introduce a struct to hold idx customization options
  index-pack: group the delta-base array entries also by type

Conflicts:
	builtin/verify-pack.c
	cache.h
	sha1_file.c
</content>
</entry>
</feed>
