[PATCH 0/4] Fix gc failure when a remote HEAD goes stale

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



There has been a report in the Git for Windows project that gc fails
sometimes: https://github.com/git-for-windows/git/issues/423

It turns out that there are cases when a remote HEAD can go stale and
it is not the user's fault at all. It can happen, for example, if the
active branch in the remote repository gets renamed.

Git's garbage collector should handle this gracefully. The best this
developer could come up with, is to simply ignore and delete the
now-broken refs.


Johannes Schindelin (4):
  gc: demonstrate failure with stale remote HEAD
  pack-objects: do not get distracted by stale refs
  mark_reachable_objects(): optionally collect broken refs
  gc: remove broken refs

 builtin/pack-objects.c |  1 +
 builtin/prune.c        | 12 +++++++++++-
 builtin/reflog.c       |  2 +-
 reachable.c            | 26 ++++++++++++++++++++------
 reachable.h            |  3 ++-
 t/t6500-gc.sh          | 15 +++++++++++++++
 6 files changed, 50 insertions(+), 9 deletions(-)

-- 
2.5.2.windows.2


--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]