This project is mirrored from https://github.com/git/git. Updated .
  1. 30 Sep, 2014 2 commits
  2. 28 Sep, 2014 1 commit
  3. 25 Sep, 2014 3 commits
  4. 19 Sep, 2014 13 commits
  5. 16 Sep, 2014 1 commit
  6. 29 Aug, 2014 3 commits
  7. 28 Aug, 2014 1 commit
  8. 26 Aug, 2014 4 commits
    • Jeff King's avatar
      send-pack: take refspecs over stdin · 26be19ba
      Jeff King authored
      Pushing a large number of refs works over most transports,
      because we implement send-pack as an internal function.
      However, it can sometimes fail when pushing over http,
      because we have to spawn "git send-pack --stateless-rpc" to
      do the heavy lifting, and we pass each refspec on the
      command line. This can cause us to overflow the OS limits on
      the size of the command line for a large push.
      
      We can solve this by giving send-pack a --stdin option and
      using it from remote-curl.  We already dealt with this on
      the fetch-pack side in 078b895f (fetch-pack: new --stdin
      option to read refs from stdin, 2012-04-02). The stdin
      option (and in particular, its use of packet-lines for
      stateless-rpc input) is modeled after that solution.
      Signed-off-by: default avatarJeff King <peff@peff.net>
      Signed-off-by: default avatarJunio C Hamano <gitster@pobox.com>
      26be19ba
    • Junio C Hamano's avatar
      Merge branch 'jk/diff-tree-t-fix' · 4109c28e
      Junio C Hamano authored
      Fix (rarely used) "git diff-tree -t" regression in 2.0.
      
      * jk/diff-tree-t-fix:
        intersect_paths: respect mode in git's tree-sort
      4109c28e
    • Junio C Hamano's avatar
      Merge branch 'jk/pack-shallow-always-without-bitmap' · a3d54f9a
      Junio C Hamano authored
      Reachability bitmaps do not work with shallow operations.
      Fixes regression in 2.0.
      
      * jk/pack-shallow-always-without-bitmap:
        pack-objects: turn off bitmaps when we see --shallow lines
      a3d54f9a
    • Junio C Hamano's avatar
      Merge branch 'jk/fix-profile-feedback-build' · 212d781c
      Junio C Hamano authored
      Fix profile-feedback build broken in 2.1 for tarball releases.
      
      * jk/fix-profile-feedback-build:
        Makefile: make perf tests optional for profile build
      212d781c
  9. 25 Aug, 2014 6 commits
    • Jonathan Nieder's avatar
      checkout -m: attempt merge when deletion of path was staged · 6a143aa2
      Jonathan Nieder authored
      twoway_merge() is missing an o->gently check in the case where a file
      that needs to be modified is missing from the index but present in the
      old and new trees.  As a result, in this case 'git checkout -m' errors
      out instead of trying to perform a merge.
      
      Fix it by checking o->gently.  While at it, inline the o->gently check
      into reject_merge to prevent future call sites from making the same
      mistake.
      
      Noticed by code inspection.  The test for the motivating case was
      added by JC.
      Signed-off-by: default avatarJonathan Nieder <jrnieder@gmail.com>
      Signed-off-by: default avatarJunio C Hamano <gitster@pobox.com>
      6a143aa2
    • Junio C Hamano's avatar
      Merge git://github.com/git-l10n/git-po · c285171d
      Junio C Hamano authored
      * git://github.com/git-l10n/git-po:
        l10n: de.po: improve message when switching branches
        l10n: de.po: fix typo
        po/TEAMS: Add Catalan team
        l10n: Add Catalan translation
        l10n: fr.po (2257t) update for version 2.1.0
        l10n: sv.po: Update Swedish translation (2257t0f0u)
        l10n: vi.po (2257t): Update translation
        l10n: Updated Bulgarian translation of git (2257t,0f,0u)
        l10n: zh_CN: translations for git v2.1.0-rc0
        l10n: git.pot: v2.1.0 round 1 (38 new, 9 removed)
        l10n: Updated Bulgarian translation of git (2247t,0f,0u)
        l10n: Updated Bulgarian translation of git (2228t,0f,0u)
        l10n: Fix more typos in the Swedish translations
      c285171d
    • Jeff King's avatar
      git-prompt: do not look for refs/stash in $GIT_DIR · 0fa7f016
      Jeff King authored
      Since dd0b72cb (bash prompt: use bash builtins to check stash
      state, 2011-04-01), git-prompt checks whether we have a
      stash by looking for $GIT_DIR/refs/stash. Generally external
      programs should never do this, because they would miss
      packed-refs.
      
      That commit claims that packed-refs does not pack
      refs/stash, but that is not quite true. It does pack the
      ref, but due to a bug, fails to prune the ref. When we fix
      that bug, we would want to be doing the right thing here.
      Signed-off-by: default avatarJeff King <peff@peff.net>
      Reviewed-by: default avatarMichael Haggerty <mhagger@alum.mit.edu>
      Reviewed-by: default avatarRonnie Sahlberg <sahlberg@google.com>
      Signed-off-by: default avatarJunio C Hamano <gitster@pobox.com>
      0fa7f016
    • Jeff King's avatar
      fast-import: fix buffer overflow in dump_tags · c2527859
      Jeff King authored
      When creating a new annotated tag, we sprintf the refname
      into a static-sized buffer. If we have an absurdly long
      tagname, like:
      
        git init repo &&
        cd repo &&
        git commit --allow-empty -m foo &&
        git tag -m message mytag &&
        git fast-export mytag |
        perl -lpe '/^tag/ and s/mytag/"a" x 8192/e' |
        git fast-import <input
      
      we'll overflow the buffer. We can fix it by using a strbuf.
      Signed-off-by: default avatarJeff King <peff@peff.net>
      Reviewed-by: default avatarMichael Haggerty <mhagger@alum.mit.edu>
      Reviewed-by: default avatarRonnie Sahlberg <sahlberg@google.com>
      Signed-off-by: default avatarJunio C Hamano <gitster@pobox.com>
      c2527859
    • Jeff King's avatar
      fast-import: clean up pack_data pointer in end_packfile · 3c078b9c
      Jeff King authored
      We have a global pointer pack_data pointing to the current
      pack we have open. Inside end_packfile we have two new
      pointers, old_p and new_p. The latter points to pack_data,
      and the former points to the new "installed" version of the
      packfile we get when we hand the file off to the regular
      sha1_file machinery. When then free old_p.
      
      Presumably the extra old_p pointer was there so that we
      could overwrite pack_data with new_p and still free old_p,
      but we don't do that. We just leave pack_data pointing to
      bogus memory, and don't overwrite it until we call
      start_packfile again (if ever).
      
      This can cause problems for our die routine, which calls
      end_packfile to clean things up. If we die at the wrong
      moment, we can end up looking at invalid memory in
      pack_data left after the last end_packfile().
      
      Instead, let's make sure we set pack_data to NULL after we
      free it, and make calling endfile() again with a NULL
      pack_data a noop (there is nothing to end).
      
      We can further make things less confusing by dropping old_p
      entirely, and moving new_p closer to its point of use.
      Signed-off-by: default avatarJeff King <peff@peff.net>
      Reviewed-by: default avatarRonnie Sahlberg <sahlberg@google.com>
      Signed-off-by: default avatarJunio C Hamano <gitster@pobox.com>
      3c078b9c
    • Jeff King's avatar
      pack-refs: prune top-level refs like "refs/foo" · afd11d3e
      Jeff King authored
      After we have packed all refs, we prune any loose refs that
      correspond to what we packed. We do so by first taking a
      lock with lock_ref_sha1, and then deleting the loose ref
      file.
      
      However, lock_ref_sha1 will refuse to take a lock on any
      refs that exist at the top-level of the "refs/" directory,
      and we skip pruning the ref.  This is almost certainly not
      what we want to happen here. The criteria to be pruned
      should not differ from that to be packed; if a ref makes it
      to prune_ref, it's because we want it both packed and
      pruned (if there are refs you do not want to be packed, they
      should be omitted much earlier by pack_ref_is_possible,
      which we do in this case if --all is not given).
      
      We can fix this by switching to lock_any_ref_for_update.
      This behaves exactly the same with the exception of this
      top-level check.
      Signed-off-by: default avatarJeff King <peff@peff.net>
      Reviewed-by: default avatarMichael Haggerty <mhagger@alum.mit.edu>
      Reviewed-by: default avatarRonnie Sahlberg <sahlberg@google.com>
      Signed-off-by: default avatarJunio C Hamano <gitster@pobox.com>
      afd11d3e
  10. 23 Aug, 2014 4 commits
  11. 22 Aug, 2014 1 commit
  12. 20 Aug, 2014 1 commit
    • Jeff King's avatar
      intersect_paths: respect mode in git's tree-sort · e09867f0
      Jeff King authored
      When we do a combined diff, we individually diff against
      each parent, and then use intersect_paths to do a parallel
      walk through the sorted results and come up with a final
      list of interesting paths.
      
      The sort order here is that returned by the diffs, which
      means it is in git's tree-order which sorts sub-trees as if
      their paths have "/" at the end. When we do our parallel
      walk, we need to use a comparison function which provides
      the same order.
      
      Since 8518ff8f (combine-diff: optimize combine_diff_path sets
      intersection, 2014-01-20), we use a simple strcmp to
      compare the pathnames, and get this wrong. It's somewhat
      hard to trigger because normally a diff does not produce
      tree entries at all, and therefore the sort order is the
      same as a strcmp. However, if the "-t" option is used with
      the diff, then we will produce diff_filepairs for both trees
      and files.
      
      We can use base_name_compare to do the comparison, just as
      the tree-diff code does. Even though what we have are not
      technically base names (they are full paths within the
      tree), the end result is the same (we do not care about
      interior slashes at all, only about the final character).
      
      However, since we do not have the length of each path
      stored, we take a slight shortcut: if neither of the entries
      is a sub-tree then the comparison is equivalent to a strcmp.
      This lets us skip the extra strlen calls in the common case
      without having to reimplement base_name_compare from
      scratch.
      Signed-off-by: default avatarJeff King <peff@peff.net>
      Signed-off-by: default avatarJunio C Hamano <gitster@pobox.com>
      e09867f0