[git commit] cut: remove unnecessary initialization of regmatch_t

Denys Vlasenko vda.linux at googlemail.com
Fri Dec 20 20:46:32 UTC 2024


commit: https://git.busybox.net/busybox/commit/?id=dd40b40ee59e1eae6a70265741657bc55d960cce
branch: https://git.busybox.net/busybox/commit/?id=refs/heads/master

function                                             old     new   delta
cut_main                                            1404    1388     -16

Signed-off-by: Denys Vlasenko <vda.linux at googlemail.com>
---
 coreutils/cut.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/coreutils/cut.c b/coreutils/cut.c
index 74a704c8f..a766db40f 100644
--- a/coreutils/cut.c
+++ b/coreutils/cut.c
@@ -222,7 +222,7 @@ static void cut_file(FILE *file, const char *delim, const char *odelim,
 					/* Find next delimiter */
 #if ENABLE_FEATURE_CUT_REGEX
 					if (opt_REGEX) {
-						regmatch_t rr = {-1, -1};
+						regmatch_t rr;
 						regex_t *reg = (void*) delim;
 
 						if (regexec(reg, line + next, 1, &rr, REG_NOTBOL|REG_NOTEOL) != 0) {


More information about the busybox-cvs mailing list