aboutsummaryrefslogtreecommitdiff
path: root/usr.bin/patch
diff options
context:
space:
mode:
authorPedro F. Giffuni <pfg@FreeBSD.org>2014-12-07 20:32:24 +0000
committerPedro F. Giffuni <pfg@FreeBSD.org>2014-12-07 20:32:24 +0000
commit2b468ebac35a7c1607f0027500705a3ba9366b7b (patch)
tree26b1a9fadb7fb8a0645daa82cb8bc155adfc7885 /usr.bin/patch
parentab761cdbfa355a486d0df954faf6172d4d60628c (diff)
Notes
Diffstat (limited to 'usr.bin/patch')
-rw-r--r--usr.bin/patch/pch.c19
1 files changed, 11 insertions, 8 deletions
diff --git a/usr.bin/patch/pch.c b/usr.bin/patch/pch.c
index 949f156565d98..e2daba8889ee1 100644
--- a/usr.bin/patch/pch.c
+++ b/usr.bin/patch/pch.c
@@ -24,7 +24,7 @@
* -C option added in 1998, original code by Marc Espie, based on FreeBSD
* behaviour
*
- * $OpenBSD: pch.c,v 1.40 2013/07/11 12:39:31 otto Exp $
+ * $OpenBSD: pch.c,v 1.43 2014/11/18 17:03:35 tobias Exp $
* $FreeBSD$
*/
@@ -319,7 +319,8 @@ intuit_diff_type(void)
for (t = s + 7; isspace((unsigned char)*t); t++)
;
revision = savestr(t);
- for (t = revision; *t && !isspace((unsigned char)*t); t++)
+ for (t = revision;
+ *t && !isspace((unsigned char)*t); t++)
;
*t = '\0';
if (*revision == '\0') {
@@ -585,7 +586,8 @@ another_hunk(void)
p_end--;
return false;
}
- for (s = buf; *s && !isdigit((unsigned char)*s); s++)
+ for (s = buf;
+ *s && !isdigit((unsigned char)*s); s++)
;
if (!*s)
malformed();
@@ -595,7 +597,8 @@ another_hunk(void)
while (isdigit((unsigned char)*s))
s++;
if (*s == ',') {
- for (; *s && !isdigit((unsigned char)*s); s++)
+ for (;
+ *s && !isdigit((unsigned char)*s); s++)
;
if (!*s)
malformed();
@@ -692,8 +695,8 @@ another_hunk(void)
change_line:
if (buf[1] == '\n' && canonicalize)
strlcpy(buf + 1, " \n", buf_size - 1);
- if (!isspace((unsigned char)buf[1]) && buf[1] != '>' &&
- buf[1] != '<' &&
+ if (!isspace((unsigned char)buf[1]) &&
+ buf[1] != '>' && buf[1] != '<' &&
repl_beginning && repl_could_be_missing) {
repl_missing = true;
goto hunk_done;
@@ -1422,8 +1425,8 @@ do_ed_script(void)
for (t = buf; isdigit((unsigned char)*t) || *t == ','; t++)
;
/* POSIX defines allowed commands as {a,c,d,i,s} */
- if (isdigit((unsigned char)*buf) && (*t == 'a' || *t == 'c' ||
- *t == 'd' || *t == 'i' || *t == 's')) {
+ if (isdigit((unsigned char)*buf) &&
+ (*t == 'a' || *t == 'c' || *t == 'd' || *t == 'i' || *t == 's')) {
if (pipefp != NULL)
fputs(buf, pipefp);
if (*t != 'd') {