Skip to content

sequencer: truncate lockfile and ref to NAME_MAX

Mark Ruvald Pedersen via GitGitGadget git 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest2 patches 4 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/2sequencer: truncate labels to accommodate loose refsgit-compat-util.h sequencer.c+40 -53 replies
2/2rebase: allow overriding the maximal length of the generated labelsDocumentation/config/rebase.txt sequencer.c t/t3430-rebase-merges.sh+23 -21 reply

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [PATCH 0/2] sequencer: truncate lockfile and ref to NAME_MAX

Some commits may have unusually long subject lines, which can cause git error out. Currently the sequencer and lockfile assumes these to be less than NAME_MAX which is the maximum length of a filename (on Linux).

When reproduced one is met by the error message:

$ git rebase --continue
error: cannot lock ref 'refs/rewritten/SANITIZED-SUBJECT': Unable to create '.git/refs/rewritten/SANITIZED-SUBJECT.lock': File name too long

* where SANITIZED-SUBJECT is very long

Affected repos can only be salvaged through filter-branch etc.

Johannes Schindelin (1):
rebase: allow overriding the maximal length of the generated labels

Mark Ruvald Pedersen (1):
sequencer: truncate labels to accommodate loose refs

 Documentation/config/rebase.txt |  6 +++++
 git-compat-util.h               |  4 +++
 sequencer.c                     | 47 ++++++++++++++++++++++++++++-----
 t/t3430-rebase-merges.sh        | 11 ++++++++
 4 files changed, 62 insertions(+), 6 deletions(-)

base-commit: a82fb66fed250e16d3010c75404503bea3f0ab61
Published-As: https://github.com/gitgitgadget/git/releases/tag/pr-git-1562%2Fmped-oticon%2Fmped_bugfix_lockfile_maxname-v1
Fetch-It-Via: git fetch https://github.com/gitgitgadget/git pr-git-1562/mped-oticon/mped_bugfix_lockfile_maxname-v1
Pull-Request: https://github.com/git/git/pull/1562

Signature · 1 line
gitgitgadget