aboutsummaryrefslogtreecommitdiffstats
path: root/main/busybox/0010-Add-flag-for-not-following-symlinks-when-recursing.patch
diff options
context:
space:
mode:
authorSören Tempel <soeren+git@soeren-tempel.net>2018-03-06 16:54:09 +0100
committerSören Tempel <soeren+git@soeren-tempel.net>2018-03-11 14:27:25 +0100
commitdc6cfb7cebc64cdb278f02d32f897819bba5f983 (patch)
tree04cb1d5a44a1da6d2420fbfe2eaf6a5c0c728cb8 /main/busybox/0010-Add-flag-for-not-following-symlinks-when-recursing.patch
parent4923b942bfc1889d3b2f3f6cb20b2aeef6a65f06 (diff)
downloadaports-dc6cfb7cebc64cdb278f02d32f897819bba5f983.tar.gz
aports-dc6cfb7cebc64cdb278f02d32f897819bba5f983.tar.bz2
aports-dc6cfb7cebc64cdb278f02d32f897819bba5f983.tar.xz
main/busybox: upgrade to 1.28.1
Diffstat (limited to 'main/busybox/0010-Add-flag-for-not-following-symlinks-when-recursing.patch')
-rw-r--r--main/busybox/0010-Add-flag-for-not-following-symlinks-when-recursing.patch59
1 files changed, 59 insertions, 0 deletions
diff --git a/main/busybox/0010-Add-flag-for-not-following-symlinks-when-recursing.patch b/main/busybox/0010-Add-flag-for-not-following-symlinks-when-recursing.patch
new file mode 100644
index 0000000000..a45c46d09d
--- /dev/null
+++ b/main/busybox/0010-Add-flag-for-not-following-symlinks-when-recursing.patch
@@ -0,0 +1,59 @@
+From 1c8c2316f98c2e4894c4c1686f0aa7937fcc0a17 Mon Sep 17 00:00:00 2001
+From: Natanael Copa <ncopa@alpinelinux.org>
+Date: Fri, 25 Jul 2014 15:28:33 +0200
+Subject: [PATCH 10/16] Add flag for not following symlinks when recursing
+
+function old new delta
+.rodata 7934 7967 +33
+diff_longopts 253 270 +17
+packed_usage 1704 1720 +16
+diff_main 1665 1662 -3
+------------------------------------------------------------------------------
+(add/remove: 0/0 grow/shrink: 3/1 up/down: 66/-3) Total: 63 bytes
+---
+ editors/diff.c | 8 +++++++-
+ 1 file changed, 7 insertions(+), 1 deletion(-)
+
+diff --git a/editors/diff.c b/editors/diff.c
+index 1462a9b18..2c899578e 100644
+--- a/editors/diff.c
++++ b/editors/diff.c
+@@ -113,6 +113,9 @@
+ //usage: "\n -N Treat absent files as empty"
+ //usage: "\n -q Output only whether files differ"
+ //usage: "\n -r Recurse"
++//usage: IF_LONG_OPTS(
++//usage: "\n --no-dereference Don't follow symlinks"
++//usage: )
+ //usage: "\n -S Start with FILE when comparing directories"
+ //usage: "\n -T Make tabs line up by prefixing a tab when necessary"
+ //usage: "\n -s Report when two files are the same"
+@@ -154,6 +157,7 @@ enum { /* Commandline flags */
+ FLAG_p, /* not implemented */
+ FLAG_B,
+ FLAG_E, /* not implemented */
++ FLAG_no_deref,
+ };
+ #define FLAG(x) (1 << FLAG_##x)
+
+@@ -867,7 +871,8 @@ static void diffdir(char *p[2], const char *s_start)
+ * Using list.len to specify its length,
+ * add_to_dirlist will remove it. */
+ list[i].len = strlen(p[i]);
+- recursive_action(p[i], ACTION_RECURSE | ACTION_FOLLOWLINKS,
++ recursive_action(p[i], ACTION_RECURSE |
++ ((option_mask32 & FLAG(no_deref)) ? 0 : ACTION_FOLLOWLINKS),
+ add_to_dirlist, skip_dir, &list[i], 0);
+ /* Sort dl alphabetically.
+ * GNU diff does this ignoring any number of trailing dots.
+@@ -964,6 +969,7 @@ static const char diff_longopts[] ALIGN1 =
+ "report-identical-files\0" No_argument "s"
+ "starting-file\0" Required_argument "S"
+ "minimal\0" No_argument "d"
++ "no-dereference\0" No_argument "\xff"
+ ;
+ # define GETOPT32 getopt32long
+ # define LONGOPTS ,diff_longopts
+--
+2.16.2
+