summaryrefslogtreecommitdiffstats
path: root/groff-1.18.1-gzext.patch
diff options
context:
space:
mode:
Diffstat (limited to 'groff-1.18.1-gzext.patch')
-rw-r--r--groff-1.18.1-gzext.patch18
1 files changed, 11 insertions, 7 deletions
diff --git a/groff-1.18.1-gzext.patch b/groff-1.18.1-gzext.patch
index d9ea585..3ab3aac 100644
--- a/groff-1.18.1-gzext.patch
+++ b/groff-1.18.1-gzext.patch
@@ -1,11 +1,16 @@
---- groff-1.18.1/src/roff/troff/input.cc.gzext 2003-02-10 18:32:00.000000000 +0100
-+++ groff-1.18.1/src/roff/troff/input.cc 2003-02-10 18:33:18.000000000 +0100
-@@ -5487,12 +5487,16 @@
+--- groff-1.19.1/src/roff/troff/input.cpp.gzext 2005-01-12 14:17:15.469480712 +0100
++++ groff-1.19.1/src/roff/troff/input.cpp 2005-01-12 14:22:57.666458864 +0100
+@@ -5590,16 +5590,20 @@ void source()
+ else {
char cbuf[PATH_MAX], * cwd;
char pbuf[PATH_MAX], * path;
- struct stat st;
+ char tmp[PATH_MAX];
+ struct stat st;
+
+ snprintf(tmp, PATH_MAX, "%s.gz", nm.contents());
++
+ while (!tok.newline() && !tok.eof())
+ tok.next();
if ((cwd = realpath(".", cbuf)) == NULL)
error("realpath on `%1' failed: %2", ".", strerror(errno));
@@ -13,9 +18,8 @@
- error("realpath on `%1' failed: %2", nm.contents(), strerror(errno));
- else if (safer_flag && strncmp(cwd, path, strlen(cwd)))
+ else if ((path = realpath(nm.contents(), pbuf)) == NULL &&
-+ (path = realpath(tmp, pbuf)) == NULL)
-+ {
-+ error("realpath on `%1' failed: %3", nm.contents(), strerror(errno));
++ (path = realpath(tmp, pbuf)) == NULL) {
++ error("realpath on `%1' failed: %3", nm.contents(), strerror(errno));
+ } else if (safer_flag && strncmp(cwd, path, strlen(cwd)))
error("won't source `%1' outside of `%2' without -U flag", path, cwd);
else if (stat(path, &st) < 0)