1. 18 3月, 2014 1 次提交
    • J
      shallow: verify shallow file after taking lock · 78396321
      Jeff King 提交于
      Before writing the shallow file, we stat() the existing file
      to make sure it has not been updated since our operation
      began. However, we do not do so under a lock, so there is a
      possible race:
      
        1. Process A takes the lock.
      
        2. Process B calls check_shallow_file_for_update and finds
           no update.
      
        3. Process A commits the lockfile.
      
        4. Process B takes the lock, then overwrite's process A's
           changes.
      
      We can fix this by doing our check while we hold the lock.
      Signed-off-by: NJeff King <peff@peff.net>
      Signed-off-by: NJunio C Hamano <gitster@pobox.com>
      78396321
  2. 28 2月, 2014 2 次提交
    • J
      shallow: automatically clean up shallow tempfiles · 0179c945
      Jeff King 提交于
      We sometimes write tempfiles of the form "shallow_XXXXXX"
      during fetch/push operations with shallow repositories.
      Under normal circumstances, we clean up the result when we
      are done. However, we do no take steps to clean up after
      ourselves when we exit due to die() or signal death.
      
      This patch teaches the tempfile creation code to register
      handlers to clean up after ourselves. To handle this, we
      change the ownership semantics of the filename returned by
      setup_temporary_shallow. It now keeps a copy of the filename
      itself, and returns only a const pointer to it.
      
      We can also do away with explicit tempfile removal in the
      callers. They all exit not long after finishing with the
      file, so they can rely on the auto-cleanup, simplifying the
      code.
      
      Note that we keep things simple and maintain only a single
      filename to be cleaned. This is sufficient for the current
      caller, but we future-proof it with a die("BUG").
      Signed-off-by: NJeff King <peff@peff.net>
      Signed-off-by: NJunio C Hamano <gitster@pobox.com>
      0179c945
    • J
      shallow: use stat_validity to check for up-to-date file · 0cc77c38
      Jeff King 提交于
      When we are about to write the shallow file, we check that
      it has not changed since we last read it. Instead of
      hand-rolling this, we can use stat_validity. This is built
      around the index stat-check, so it is more robust than just
      checking the mtime, as we do now (it uses the same check as
      we do for index files).
      
      The new code also handles the case of a shallow file
      appearing unexpectedly. With the current code, two
      simultaneous processes making us shallow (e.g., two "git
      fetch --depth=1" running at the same time in a non-shallow
      repository) can race to overwrite each other.
      
      As a bonus, we also remove a race in determining the stat
      information of what we read (we stat and then open, leaving
      a race window; instead we should open and then fstat the
      descriptor).
      Signed-off-by: NJeff King <peff@peff.net>
      Signed-off-by: NJunio C Hamano <gitster@pobox.com>
      0cc77c38
  3. 15 2月, 2014 2 次提交
  4. 14 2月, 2014 9 次提交
    • J
      Sync with 1.8.5.5 · 475c52b7
      Junio C Hamano 提交于
      Signed-off-by: NJunio C Hamano <gitster@pobox.com>
      475c52b7
    • J
      Git 1.8.5.5 · 7bbc4e8f
      Junio C Hamano 提交于
      Signed-off-by: NJunio C Hamano <gitster@pobox.com>
      7bbc4e8f
    • J
      Merge branch 'bm/merge-base-octopus-dedup' into maint · 2cd86167
      Junio C Hamano 提交于
      "git merge-base --octopus" used to leave cleaning up suboptimal
      result to the caller, but now it does the clean-up itself.
      
      * bm/merge-base-octopus-dedup:
        merge-base --octopus: reduce the result from get_octopus_merge_bases()
        merge-base: separate "--independent" codepath into its own helper
      2cd86167
    • J
      Merge branch 'jc/revision-range-unpeel' into maint · 50320986
      Junio C Hamano 提交于
      "git log --left-right A...B" lost the "leftness" of commits
      reachable from A when A is a tag as a side effect of a recent
      bugfix.  This is a regression in 1.8.4.x series.
      
      * jc/revision-range-unpeel:
        revision: propagate flag bits from tags to pointees
        revision: mark contents of an uninteresting tree uninteresting
      50320986
    • J
      Merge branch 'jk/allow-fetch-onelevel-refname' into maint · c3376848
      Junio C Hamano 提交于
      "git clone" would fail to clone from a repository that has a ref
      directly under "refs/", e.g. "refs/stash", because different
      validation paths do different things on such a refname.  Loosen the
      client side's validation to allow such a ref.
      
      * jk/allow-fetch-onelevel-refname:
        fetch-pack: do not filter out one-level refs
      c3376848
    • J
      Merge branch 'jk/interpret-branch-name-fix' into maint · 21261fab
      Junio C Hamano 提交于
      A handful of bugs around interpreting $branch@{upstream} notation
      and its lookalike, when $branch part has interesting characters,
      e.g. "@", and ":", have been fixed.
      
      * jk/interpret-branch-name-fix:
        interpret_branch_name: find all possible @-marks
        interpret_branch_name: avoid @{upstream} past colon
        interpret_branch_name: always respect "namelen" parameter
        interpret_branch_name: rename "cp" variable to "at"
        interpret_branch_name: factor out upstream handling
      21261fab
    • J
      Merge branch 'rk/send-email-ssl-cert' into maint · 7c9b668b
      Junio C Hamano 提交于
      A recent update to "git send-email" broke platforms where
      /etc/ssl/certs/ directory exists but cannot be used as SSL_ca_path
      (e.g. Fedora rawhide).
      
      * rk/send-email-ssl-cert:
        send-email: /etc/ssl/certs/ directory may not be usable as ca_path
      7c9b668b
    • J
      Merge branch 'sb/repack-in-c' into maint · 90791e34
      Junio C Hamano 提交于
      "git repack --max-pack-size=8g" stopped being parsed correctly when
      the command was reimplemented in C.
      
      * sb/repack-in-c:
        repack: propagate pack-objects options as strings
        repack: make parsed string options const-correct
        repack: fix typo in max-pack-size option
      90791e34
    • J
      Merge branch 'as/tree-walk-fix-aggressive-short-cut' into maint · b4e931d8
      Junio C Hamano 提交于
      The pathspec matching code, while comparing two trees (e.g. "git
      diff A B -- path1 path2") was too aggressive and failed to match
      some paths when multiple pathspecs were involved.
      
      * as/tree-walk-fix-aggressive-short-cut:
        tree_entry_interesting: match against all pathspecs
      b4e931d8
  5. 13 2月, 2014 1 次提交
  6. 12 2月, 2014 3 次提交
  7. 08 2月, 2014 4 次提交
  8. 06 2月, 2014 18 次提交
    • J
      l10n: zh_CN.po: Disambiguation for rebase · 98b2761d
      Jiang Xin 提交于
      Disambiguate the Chinese translation for "rebase", and update other
      related entries.
      Signed-off-by: NJiang Xin <worldhello.net@gmail.com>
      98b2761d
    • Ø
      Documentation: fix typos in man pages · 5fe8f49b
      Øystein Walle 提交于
      Signed-off-by: NØystein Walle <oystwa@gmail.com>
      Signed-off-by: NJunio C Hamano <gitster@pobox.com>
      5fe8f49b
    • J
      Sync with 1.8.5.4 · 89ba81dc
      Junio C Hamano 提交于
      89ba81dc
    • J
      howto/maintain-git.txt: new version numbering scheme · c7b8cf49
      Junio C Hamano 提交于
      We wanted to call the upcoming release "Git 1.9", with its
      maintenance track being "Git 1.9.1", "Git 1.9.2", etc., but various
      third-party tools are reported to assume that there are at least
      three dewey-decimal components in our version number.
      
      Adjust the plan so that vX.Y.0 are feature releases while vX.Y.Z
      (Z > 0) are maintenance releases.
      Signed-off-by: NJunio C Hamano <gitster@pobox.com>
      c7b8cf49
    • J
      Git 1.8.5.4 · 3330a2c4
      Junio C Hamano 提交于
      Signed-off-by: NJunio C Hamano <gitster@pobox.com>
      3330a2c4
    • J
      Merge branch 'jc/maint-pull-docfix' into maint · 01a57745
      Junio C Hamano 提交于
      The documentation to "git pull" hinted there is an "-m" option
      because it incorrectly shared the documentation with "git merge".
      
      * jc/maint-pull-docfix:
        Documentation: "git pull" does not have the "-m" option
        Documentation: exclude irrelevant options from "git pull"
      01a57745
    • J
      Merge branch 'ow/stash-with-ifs' into maint · a74a682b
      Junio C Hamano 提交于
      The implementation of 'git stash $cmd "stash@{...}"' did not quote
      the stash argument properly and left it split at IFS whitespace.
      
      * ow/stash-with-ifs:
        stash: handle specifying stashes with $IFS
      a74a682b
    • J
      Merge branch 'js/lift-parent-count-limit' into maint · 3c864743
      Junio C Hamano 提交于
      There is no reason to have a hardcoded upper limit of the number of
      parents for an octopus merge, created via the graft mechanism, but
      there was.
      
      * js/lift-parent-count-limit:
        Remove the line length limit for graft files
      3c864743
    • J
      Merge branch 'nd/add-empty-fix' into maint · ee5788e3
      Junio C Hamano 提交于
      "git add -A" (no other arguments) in a totally empty working tree
      used to emit an error.
      
      * nd/add-empty-fix:
        add: don't complain when adding empty project root
      ee5788e3
    • J
      Merge branch 'bc/log-decoration' into maint · d11ade70
      Junio C Hamano 提交于
      "git log --decorate" did not handle a tag pointed by another tag
      nicely.
      
      * bc/log-decoration:
        log: properly handle decorations with chained tags
      d11ade70
    • J
      Merge branch 'jh/rlimit-nofile-fallback' into maint · 28856247
      Junio C Hamano 提交于
      When we figure out how many file descriptors to allocate for
      keeping packfiles open, a system with non-working getrlimit() could
      cause us to die(), but because we make this call only to get a
      rough estimate of how many is available and we do not even attempt
      to use up all file descriptors available ourselves, it is nicer to
      fall back to a reasonable low value rather than dying.
      
      * jh/rlimit-nofile-fallback:
        get_max_fd_limit(): fall back to OPEN_MAX upon getrlimit/sysconf failure
      28856247
    • J
      Merge branch 'jl/commit-v-strip-marker' into maint · a118beed
      Junio C Hamano 提交于
      "git commit -v" appends the patch to the log message before
      editing, and then removes the patch when the editor returned
      control. However, the patch was not stripped correctly when the
      first modified path was a submodule.
      
      * jl/commit-v-strip-marker:
        commit -v: strip diffs and submodule shortlogs from the commit message
      a118beed
    • J
      Merge branch 'tr/send-email-ssl' into maint · ac0835f9
      Junio C Hamano 提交于
      SSL-related options were not passed correctly to underlying socket
      layer in "git send-email".
      
      * tr/send-email-ssl:
        send-email: set SSL options through IO::Socket::SSL::set_client_defaults
        send-email: --smtp-ssl-cert-path takes an argument
        send-email: pass Debug to Net::SMTP::SSL::new
      ac0835f9
    • J
      Merge branch 'tb/clone-ssh-with-colon-for-port' into maint · 1a111957
      Junio C Hamano 提交于
      Remote repository URL expressed in scp-style host:path notation are
      parsed more carefully (e.g. "foo/bar:baz" is local, "[::1]:/~user" asks
      to connect to user's home directory on host at address ::1.
      
      * tb/clone-ssh-with-colon-for-port:
        git_connect(): use common return point
        connect.c: refactor url parsing
        git_connect(): refactor the port handling for ssh
        git fetch: support host:/~repo
        t5500: add test cases for diag-url
        git fetch-pack: add --diag-url
        git_connect: factor out discovery of the protocol and its parts
        git_connect: remove artificial limit of a remote command
        t5601: add tests for ssh
        t5601: remove clear_ssh, refactor setup_ssh_wrapper
      1a111957
    • J
      Merge branch 'nd/transport-positive-depth-only' into maint · bf03d6e9
      Junio C Hamano 提交于
      "git fetch --depth=0" was a no-op, and was silently ignored.
      Diagnose it as an error.
      
      * nd/transport-positive-depth-only:
        clone,fetch: catch non positive --depth option value
      bf03d6e9
    • J
      Merge branch 'tb/repack-fix-renames' (early part) · 2171c0c3
      Junio C Hamano 提交于
      Finishing touches to the "rewrite repack in C" series.
      
      * 'tb/repack-fix-renames' (early part):
        repack.c: rename and unlink pack file if it exists
      2171c0c3
    • T
      repack.c: rename and unlink pack file if it exists · 9d7fbfd2
      Torsten Bögershausen 提交于
      When a repo was fully repacked, and is repacked again, we may run
      into the situation that "new" packfiles have the same name as
      already existing ones (traditionally packfiles have been named after
      the list of names of objects in them, so repacking all the objects
      in a single pack would have produced a packfile with the same name).
      
      The logic is to rename the existing ones into filename like
      "old-XXX", create the new ones and then remove the "old-" ones.
      When something went wrong in the middle, this sequence is rolled
      back by renaming the "old-" files back.
      
      The renaming into "old-" did not work as intended, because
      file_exists() was done on "XXX", not "pack-XXX".  Also when rolling
      back the change, the code tried to rename "old-pack-XXX" but the
      saved ones are named "old-XXX", so this couldn't have worked.
      Signed-off-by: NTorsten Bögershausen <tboegi@web.de>
      Signed-off-by: NJunio C Hamano <gitster@pobox.com>
      9d7fbfd2
    • A
      userdiff: update Ada patterns · 39a87a29
      Adrian Johnson 提交于
      - Allow extra space in "is new" and "is separate"
      - Fix bug in word regex for numbers
      Signed-off-by: NAdrian Johnson <ajohnson@redneon.com>
      Signed-off-by: NJunio C Hamano <gitster@pobox.com>
      39a87a29