Thread (43 messages) 43 messages, 3 authors, 2025-11-03
STALE239d
Revisions (2)
  1. v4 current
  2. v5 [diff vs current]

[PATCH v4 13/29] rebase: skip stripping of --trailer option prefix

From: Li Chen <hidden>
Date: 2025-10-14 12:27:15
Subsystem: the rest · Maintainer: Linus Torvalds

Removed redundant --trailer= prefix stripping in
validate_trailer_args_after_config() since OPT_STRVEC
already stores only the argument text.

Signed-off-by: Li Chen <redacted>
---
 builtin/rebase.c | 6 +-----
 1 file changed, 1 insertion(+), 5 deletions(-)
diff --git a/builtin/rebase.c b/builtin/rebase.c
index 51fb9388c7..cc90980d7d 100644
--- a/builtin/rebase.c
+++ b/builtin/rebase.c
@@ -1128,13 +1128,9 @@ static int validate_trailer_args_after_config(const struct strvec *cli_args,
 				       struct strbuf *err)
 {
 	for (size_t i = 0; i < cli_args->nr; i++) {
-		const char *raw = cli_args->v[i];
-		const char *txt; // Key[:=]Val
+		const char *txt = cli_args->v[i]; // Key[:=]Val
 		const char *sep;
 
-		if (!skip_prefix(raw, "--trailer=", &txt))
-			txt = raw;
-
 		if (!*txt) {
 			strbuf_addstr(err, _("empty --trailer argument"));
 			return -1;
-- 
2.51.0
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help