1. 27 5月, 2015 7 次提交
    • J
      Merge branch 'jc/hash-object' into maint · 1e6c8bab
      Junio C Hamano 提交于
      "hash-object --literally" introduced in v2.2 was not prepared to
      take a really long object type name.
      
      * jc/hash-object:
        write_sha1_file(): do not use a separate sha1[] array
        t1007: add hash-object --literally tests
        hash-object --literally: fix buffer overrun with extra-long object type
        git-hash-object.txt: document --literally option
      1e6c8bab
    • J
      Merge branch 'jk/rebase-quiet-noop' into maint · 5d534338
      Junio C Hamano 提交于
      "git rebase --quiet" was not quite quiet when there is nothing to
      do.
      
      * jk/rebase-quiet-noop:
        rebase: silence "git checkout" for noop rebase
      5d534338
    • J
      Merge branch 'sg/complete-decorate-full-not-long' into maint · 23903b9e
      Junio C Hamano 提交于
      The completion for "log --decorate=" parameter value was incorrect.
      
      * sg/complete-decorate-full-not-long:
        completion: fix and update 'git log --decorate=' options
      23903b9e
    • J
      Merge branch 'jk/filter-branch-use-of-sed-on-incomplete-line' into maint · a2e5c79c
      Junio C Hamano 提交于
      "filter-branch" corrupted commit log message that ends with an
      incomplete line on platforms with some "sed" implementations that
      munge such a line.  Work it around by avoiding to use "sed".
      
      * jk/filter-branch-use-of-sed-on-incomplete-line:
        filter-branch: avoid passing commit message through sed
      a2e5c79c
    • J
      Merge branch 'jc/daemon-no-ipv6-for-2.4.1' into maint · 6fd58363
      Junio C Hamano 提交于
      "git daemon" fails to build from the source under NO_IPV6
      configuration (regression in 2.4).
      
      * jc/daemon-no-ipv6-for-2.4.1:
        daemon: unbreak NO_IPV6 build regression
      6fd58363
    • J
      Merge branch 'jk/stash-require-clean-index' into maint · cb9ec8e2
      Junio C Hamano 提交于
      "git stash pop/apply" forgot to make sure that not just the working
      tree is clean but also the index is clean. The latter is important
      as a stash application can conflict and the index will be used for
      conflict resolution.
      
      * jk/stash-require-clean-index:
        stash: require a clean index to apply
        t3903: avoid applying onto dirty index
        t3903: stop hard-coding commit sha1s
      cb9ec8e2
    • J
      Merge branch 'jk/git-no-more-argv0-path-munging' into maint · af6d7a62
      Junio C Hamano 提交于
      We have prepended $GIT_EXEC_PATH and the path "git" is installed in
      (typically "/usr/bin") to $PATH when invoking subprograms and hooks
      for almost eternity, but the original use case the latter tried to
      support was semi-bogus (i.e. install git to /opt/foo/git and run it
      without having /opt/foo on $PATH), and more importantly it has
      become less and less relevant as Git grew more mainstream (i.e. the
      users would _want_ to have it on their $PATH).  Stop prepending the
      path in which "git" is installed to users' $PATH, as that would
      interfere the command search order people depend on (e.g. they may
      not like versions of programs that are unrelated to Git in /usr/bin
      and want to override them by having different ones in /usr/local/bin
      and have the latter directory earlier in their $PATH).
      
      * jk/git-no-more-argv0-path-munging:
        stop putting argv[0] dirname at front of PATH
      af6d7a62
  2. 14 5月, 2015 9 次提交
  3. 12 5月, 2015 6 次提交
  4. 06 5月, 2015 4 次提交
    • J
      daemon: unbreak NO_IPV6 build regression · d358f771
      Junio C Hamano 提交于
      When 01cec54e (daemon: deglobalize hostname information, 2015-03-07)
      wrapped the global variables such as hostname inside a struct, it
      forgot to convert one location that spelled "hostname" that needs to
      be updated to "hi->hostname".
      
      This was inside NO_IPV6 block, and was not caught by anybody.
      Signed-off-by: NJunio C Hamano <gitster@pobox.com>
      d358f771
    • J
      write_sha1_file(): do not use a separate sha1[] array · 1427a7ff
      Junio C Hamano 提交于
      In the beginning, write_sha1_file() did not have a way to tell the
      caller the name of the object it wrote to the caller.  This was
      changed in d6d3f9d0 (This implements the new "recursive tree"
      write-tree., 2005-04-09) by adding the "returnsha1" parameter to the
      function so that the callers who are interested in the value can
      optionally pass a pointer to receive it.
      
      It turns out that all callers do want to know the name of the object
      it just has written.  Nobody passes a NULL to this parameter, hence
      it is not necessary to use a separate sha1[] array to receive the
      result from  write_sha1_file_prepare(), and copy the result to the
      returnsha1 supplied by the caller.
      Signed-off-by: NJunio C Hamano <gitster@pobox.com>
      1427a7ff
    • E
      t1007: add hash-object --literally tests · 383c3427
      Eric Sunshine 提交于
      git-hash-object learned a --literally option in 5ba9a93b
      (hash-object: add --literally option, 2014-09-11). Check that
      --literally allows object creation with a bogus type, with two
      type strings whose length is reasonably short and very long.
      Signed-off-by: NEric Sunshine <sunshine@sunshineco.com>
      Signed-off-by: NJunio C Hamano <gitster@pobox.com>
      383c3427
    • E
      hash-object --literally: fix buffer overrun with extra-long object type · 0c3db67c
      Eric Sunshine 提交于
      "hash-object" learned in 5ba9a93b (hash-object: add --literally
      option, 2014-09-11) to allow crafting a corrupt/broken object of
      unknown type.
      
      When the user-provided type is particularly long, however, it can
      overflow the relatively small stack-based character array handed to
      write_sha1_file_prepare() by hash_sha1_file() and write_sha1_file(),
      leading to stack corruption (and crash).  Introduce a custom helper
      to allow arbitrarily long typenames just for "hash-object --literally".
      
      [jc: Eric's original used a strbuf in the more common codepaths, and
      I rewrote it to avoid penalizing the non-literally code. Bugs are mine]
      Signed-off-by: NEric Sunshine <sunshine@sunshineco.com>
      Signed-off-by: NJunio C Hamano <gitster@pobox.com>
      0c3db67c
  5. 05 5月, 2015 1 次提交
  6. 04 5月, 2015 1 次提交
  7. 01 5月, 2015 1 次提交
  8. 30 4月, 2015 1 次提交
    • J
      filter-branch: avoid passing commit message through sed · df062010
      Jeff King 提交于
      On some systems (like OS X), if sed encounters input without
      a trailing newline, it will silently add it. As a result,
      "git filter-branch" on such systems may silently rewrite
      commit messages that omit a trailing newline. Even though
      this is not something we generate ourselves with "git
      commit", it's better for filter-branch to preserve the
      original data as closely as possible.
      
      We're using sed here only to strip the header fields from
      the commit object. We can accomplish the same thing with a
      shell loop. Since shell "read" calls are slow (usually one
      syscall per byte), we use "cat" once we've skipped past the
      header. Depending on the size of your commit messages, this
      is probably faster (you pay the cost to fork, but then read
      the data in saner-sized chunks). This idea is shamelessly
      stolen from Junio.
      Signed-off-by: NJeff King <peff@peff.net>
      Signed-off-by: NJunio C Hamano <gitster@pobox.com>
      df062010
  9. 29 4月, 2015 6 次提交
  10. 28 4月, 2015 4 次提交