summaryrefslogtreecommitdiff
path: root/package/busybox/busybox-1.20.0/busybox-1.20.0-sed.patch
blob: 70dc63f467546abc07a53a97a0e00fb8c250fd49 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
--- busybox-1.20.0/editors/sed.c
+++ busybox-1.20.0-sed/editors/sed.c
@@ -743,7 +743,7 @@ static int do_subst_command(sed_cmd_t *s
 		 */
 		if (!G.regmatch[0].rm_so && !G.regmatch[0].rm_eo && match_count) {
 			pipe_putc(*line++);
-			continue;
+			goto next;
 		}
 
 		match_count++;
@@ -755,7 +755,7 @@ static int do_subst_command(sed_cmd_t *s
 		) {
 			for (i = 0; i < G.regmatch[0].rm_eo; i++)
 				pipe_putc(*line++);
-			continue;
+			goto next;
 		}
 
 		/* print everything before the match */
@@ -773,7 +773,7 @@ static int do_subst_command(sed_cmd_t *s
 		/* if we're not doing this globally, get out now */
 		if (sed_cmd->which_match != 0)
 			break;
-
+ next:
 		if (*line == '\0')
 			break;