diff options
| author | Natanael Copa <ncopa@alpinelinux.org> | 2010-07-09 09:57:57 +0000 |
|---|---|---|
| committer | Natanael Copa <ncopa@alpinelinux.org> | 2010-07-09 09:57:57 +0000 |
| commit | 2728f1bf9db999a885ce77618b1d615646e4294f (patch) | |
| tree | 70ce8800a9c4628f7d55b9e27d822beb6660ae3c /main/busybox/diff.patch | |
| parent | b52ed2e8577385022ce7a3d694410ef2159a3647 (diff) | |
| download | aports-2728f1bf9db999a885ce77618b1d615646e4294f.tar.bz2 aports-2728f1bf9db999a885ce77618b1d615646e4294f.tar.xz | |
main/busybox: fix for diff
fixes #381
Diffstat (limited to 'main/busybox/diff.patch')
| -rw-r--r-- | main/busybox/diff.patch | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/main/busybox/diff.patch b/main/busybox/diff.patch new file mode 100644 index 0000000000..947be700bd --- /dev/null +++ b/main/busybox/diff.patch @@ -0,0 +1,29 @@ +commit d1ed648727f3a0df2d067d869040306ba1e2c52e +Author: Natanael Copa <natanael.copa@gmail.com> +Date: Fri Jul 9 09:38:03 2010 +0000 + + diff: strip trailing / on dirs + + fixes #2203 + https://bugs.busybox.net/show_bug.cgi?id=2203 + +diff --git a/editors/diff.c b/editors/diff.c +index 07594e8..e2da626 100644 +--- a/editors/diff.c ++++ b/editors/diff.c +@@ -788,9 +788,15 @@ static void diffdir(char *p[2], const char *s_start) + + memset(&list, 0, sizeof(list)); + for (i = 0; i < 2; i++) { ++ char *lc; + /*list[i].s = list[i].e = 0; - memset did it */ + /*list[i].dl = NULL; */ + ++ /* trim trailing / in dirs. */ ++ lc = last_char_is(p[i], '/'); ++ if (lc && lc != p[i]) ++ *lc = '\0'; ++ + /* We need to trim root directory prefix. + * Using list.len to specify its length, + * add_to_dirlist will remove it. */ |
