- update to 1.6.5.1

- patches merged
- enscript-1.6.1-config.patch
- enscript-doublefree.patch
- enscript-1.6.1-CAN-2004-1185.patch
- enscript-1.6.1-CAN-2004-1186.patch
- enscript-CVE-2008-3863+CVE-2008-4306.patch
- license changed to GPLv3+
This commit is contained in:
Adam Tkac 2010-05-21 11:20:35 +00:00
parent aef8174b47
commit a614ff1a07
11 changed files with 137 additions and 431 deletions

View File

@ -1,3 +1,3 @@
enscript-1.6.4.tar.gz
enscript-ruby-1.6.4.tar.gz
enscript-php-1.6.4.st enscript-php-1.6.4.st
enscript-ruby-1.6.4.tar.gz
enscript-1.6.5.1.tar.gz

View File

@ -1,24 +0,0 @@
diff -up enscript-1.6.4/src/psgen.c.CAN-2004-1185 enscript-1.6.4/src/psgen.c
--- enscript-1.6.4/src/psgen.c.CAN-2004-1185 2008-08-08 11:18:06.000000000 +0200
+++ enscript-1.6.4/src/psgen.c 2008-08-08 11:17:57.000000000 +0200
@@ -2386,9 +2386,11 @@ recognize_eps_file (Token *token)
MESSAGE (2, (stderr, "^@epsf=\"%s\"\n", token->u.epsf.filename));
i = strlen (token->u.epsf.filename);
+
+ /*
if (i > 0 && token->u.epsf.filename[i - 1] == '|')
{
- /* Read EPS data from pipe. */
+ / * Read EPS data from pipe. * /
token->u.epsf.pipe = 1;
token->u.epsf.filename[i - 1] = '\0';
token->u.epsf.fp = popen (token->u.epsf.filename, "r");
@@ -2401,6 +2403,7 @@ recognize_eps_file (Token *token)
}
}
else
+ */
{
char *filename;

View File

@ -1,14 +0,0 @@
--- enscript-1.6.1/src/psgen.c.CAN-2004-1186 2005-01-10 15:57:07.432740602 +0000
+++ enscript-1.6.1/src/psgen.c 2005-01-10 15:58:24.606016206 +0000
@@ -1914,8 +1914,9 @@
else
{
ftail++;
- strncpy (buf, fname, ftail - fname);
- buf[ftail - fname] = '\0';
+ i = ftail - fname >= sizeof (buf)-1 ? sizeof (buf)-1 : ftail - fname;
+ strncpy (buf, fname, i);
+ buf[i] = '\0';
}
if (nup > 1)

View File

@ -1,56 +0,0 @@
diff -up enscript-1.6.4/afm/Makefile.am.config enscript-1.6.4/afm/Makefile.am
--- enscript-1.6.4/afm/Makefile.am.config 2003-03-05 08:26:16.000000000 +0100
+++ enscript-1.6.4/afm/Makefile.am 2009-11-30 14:38:34.410478926 +0100
@@ -36,11 +36,11 @@ public_fonts = matrix.afm matrix.pfa
EXTRA_DIST = font.map $(default_afm) $(public_fonts)
install-data-local:
- $(top_srcdir)/mkinstalldirs $(datadir)/enscript
- $(top_srcdir)/mkinstalldirs $(datadir)/enscript/afm
+ $(top_srcdir)/mkinstalldirs $(DESTDIR)/$(datadir)/enscript
+ $(top_srcdir)/mkinstalldirs $(DESTDIR)/$(datadir)/enscript/afm
for f in $(EXTRA_DIST); do \
- $(INSTALL_DATA) $(srcdir)/$$f $(datadir)/enscript/afm/$$f; \
+ $(INSTALL_DATA) $(srcdir)/$$f $(DESTDIR)/$(datadir)/enscript/afm/$$f; \
done
uninstall-local:
- rm -rf $(datadir)/enscript/afm
+ rm -rf $(DESTDIR)/$(datadir)/enscript/afm
diff -up enscript-1.6.4/lib/Makefile.am.config enscript-1.6.4/lib/Makefile.am
--- enscript-1.6.4/lib/Makefile.am.config 2009-11-30 14:39:38.377977061 +0100
+++ enscript-1.6.4/lib/Makefile.am 2009-11-30 14:40:13.887977573 +0100
@@ -38,12 +38,12 @@ CLEANFILES = enscript.cfg
all-local: enscript.cfg
install-data-local: enscript.cfg
- $(top_srcdir)/mkinstalldirs $(sysconfdir)
- if test -r $(sysconfdir)/enscript.cfg; then \
- cp $(sysconfdir)/enscript.cfg $(sysconfdir)/enscript.cfg.old; \
+ $(top_srcdir)/mkinstalldirs $(DESTDIR)$(sysconfdir)
+ if test -r $(DESTDIR)$(sysconfdir)/enscript.cfg; then \
+ cp $(DESTDIR)$(sysconfdir)/enscript.cfg $(DESTDIR)$(sysconfdir)/enscript.cfg.old; \
else :; \
fi
- $(INSTALL_DATA) enscript.cfg $(sysconfdir)/enscript.cfg
+ $(INSTALL_DATA) enscript.cfg $(DESTDIR)$(sysconfdir)/enscript.cfg
uninstall-local:
rm -f $(sysconfdir)/enscript.cfg
diff -up enscript-1.6.4/states/hl/Makefile.am.config enscript-1.6.4/states/hl/Makefile.am
--- enscript-1.6.4/states/hl/Makefile.am.config 2003-03-05 08:26:33.000000000 +0100
+++ enscript-1.6.4/states/hl/Makefile.am 2009-11-30 14:38:34.410478926 +0100
@@ -45,10 +45,10 @@ states = $(misc) $(styles) $(languages)
EXTRA_DIST = $(states)
install-data-local:
- $(top_srcdir)/mkinstalldirs $(datadir)/enscript
- $(top_srcdir)/mkinstalldirs $(datadir)/enscript/hl
+ $(top_srcdir)/mkinstalldirs $(DESTDIR)/$(datadir)/enscript
+ $(top_srcdir)/mkinstalldirs $(DESTDIR)/$(datadir)/enscript/hl
for f in $(states); do \
- $(INSTALL_DATA) $(srcdir)/$$f $(datadir)/enscript/hl/$$f; \
+ $(INSTALL_DATA) $(srcdir)/$$f $(DESTDIR)/$(datadir)/enscript/hl/$$f; \
done
uninstall-local:

View File

@ -1,12 +1,7 @@
04_hilight.dpatch from Debian's 1.6.4-7 patchset, with a few changes: diff -up enscript-1.6.5.1/states/hl/changelog.st.hilight enscript-1.6.5.1/states/hl/changelog.st
o hilight *.xhtml as html --- enscript-1.6.5.1/states/hl/changelog.st.hilight 2009-01-24 21:59:34.000000000 +0100
o install php.st and ruby.st bits +++ enscript-1.6.5.1/states/hl/changelog.st 2010-05-20 15:28:08.148580599 +0200
o patch Makefile.am too @@ -43,7 +43,7 @@ state changelog extends HighlightEntry
diff -Nru enscript-1.6.4.orig/states/hl/changelog.st enscript-1.6.4/states/hl/changelog.st
--- enscript-1.6.4.orig/states/hl/changelog.st 2003-03-05 09:26:33.000000000 +0200
+++ enscript-1.6.4/states/hl/changelog.st 2006-01-09 22:02:28.000000000 +0200
@@ -43,7 +43,7 @@
} }
/* File descriptions without function names. */ /* File descriptions without function names. */
@ -15,9 +10,9 @@ diff -Nru enscript-1.6.4.orig/states/hl/changelog.st enscript-1.6.4/states/hl/ch
language_print ($1); language_print ($1);
function_name_face (true); function_name_face (true);
diff -Nru enscript-1.6.4.orig/states/hl/dylan.st enscript-1.6.4/states/hl/dylan.st diff -up enscript-1.6.5.1/states/hl/dylan.st.hilight enscript-1.6.5.1/states/hl/dylan.st
--- enscript-1.6.4.orig/states/hl/dylan.st 1970-01-01 02:00:00.000000000 +0200 --- enscript-1.6.5.1/states/hl/dylan.st.hilight 2010-05-20 15:28:08.148580599 +0200
+++ enscript-1.6.4/states/hl/dylan.st 2006-01-09 22:02:28.000000000 +0200 +++ enscript-1.6.5.1/states/hl/dylan.st 2010-05-20 15:28:08.148580599 +0200
@@ -0,0 +1,124 @@ @@ -0,0 +1,124 @@
+/** +/**
+ * Name: dylan + * Name: dylan
@ -143,9 +138,9 @@ diff -Nru enscript-1.6.4.orig/states/hl/dylan.st enscript-1.6.4/states/hl/dylan.
+mode: c +mode: c
+End: +End:
+*/ +*/
diff -Nru enscript-1.6.4.orig/states/hl/eiffel.st enscript-1.6.4/states/hl/eiffel.st diff -up enscript-1.6.5.1/states/hl/eiffel.st.hilight enscript-1.6.5.1/states/hl/eiffel.st
--- enscript-1.6.4.orig/states/hl/eiffel.st 1970-01-01 02:00:00.000000000 +0200 --- enscript-1.6.5.1/states/hl/eiffel.st.hilight 2010-05-20 15:28:08.148580599 +0200
+++ enscript-1.6.4/states/hl/eiffel.st 2006-01-09 22:02:28.000000000 +0200 +++ enscript-1.6.5.1/states/hl/eiffel.st 2010-05-20 15:28:08.148580599 +0200
@@ -0,0 +1,132 @@ @@ -0,0 +1,132 @@
+/** +/**
+ * Name: eiffel + * Name: eiffel
@ -279,10 +274,10 @@ diff -Nru enscript-1.6.4.orig/states/hl/eiffel.st enscript-1.6.4/states/hl/eiffe
+ } + }
+ +
+} +}
diff -Nru enscript-1.6.4.orig/states/hl/enscript.st enscript-1.6.4/states/hl/enscript.st diff -up enscript-1.6.5.1/states/hl/enscript.st.hilight enscript-1.6.5.1/states/hl/enscript.st
--- enscript-1.6.4.orig/states/hl/enscript.st 2003-03-05 10:31:31.000000000 +0200 --- enscript-1.6.5.1/states/hl/enscript.st.hilight 2009-12-28 00:57:12.000000000 +0100
+++ enscript-1.6.4/states/hl/enscript.st 2006-01-09 22:04:22.000000000 +0200 +++ enscript-1.6.5.1/states/hl/enscript.st 2010-05-20 15:28:08.148580599 +0200
@@ -474,24 +474,31 @@ @@ -472,24 +472,31 @@ namerules
/\.m$/ matlab; /\.m$/ matlab;
/\.(mpl|mp|maple)$/ maple; /\.(mpl|mp|maple)$/ maple;
/\.(scm|scheme)$/ scheme; /\.(scm|scheme)$/ scheme;
@ -315,7 +310,7 @@ diff -Nru enscript-1.6.4.orig/states/hl/enscript.st enscript-1.6.4/states/hl/ens
/\.js$/ javascript; /\.js$/ javascript;
/\.java$/ java; /\.java$/ java;
/\.([Pp][Aa][Ss]|[Pp][Pp]|[Pp])$/ pascal; /\.([Pp][Aa][Ss]|[Pp][Pp]|[Pp])$/ pascal;
@@ -530,6 +537,10 @@ @@ -529,6 +536,10 @@ startrules
/-\*- [Ii][Dd][Ll] -\*-/ idl; /-\*- [Ii][Dd][Ll] -\*-/ idl;
/-\*- [Pp][Ee][Rr][Ll] -\*-/ perl; /-\*- [Pp][Ee][Rr][Ll] -\*-/ perl;
/^#![ \t]*\/.*\/perl/ perl; /^#![ \t]*\/.*\/perl/ perl;
@ -326,9 +321,9 @@ diff -Nru enscript-1.6.4.orig/states/hl/enscript.st enscript-1.6.4/states/hl/ens
/^From:/ mail; /^From:/ mail;
/^#![ \t]*(\/usr)?\/bin\/[ngmt]?awk/ awk; /^#![ \t]*(\/usr)?\/bin\/[ngmt]?awk/ awk;
/^#![ \t]*(\/usr)?\/bin\/sh/ sh; /^#![ \t]*(\/usr)?\/bin\/sh/ sh;
diff -Nru enscript-1.6.4.orig/states/hl/erlang.st enscript-1.6.4/states/hl/erlang.st diff -up enscript-1.6.5.1/states/hl/erlang.st.hilight enscript-1.6.5.1/states/hl/erlang.st
--- enscript-1.6.4.orig/states/hl/erlang.st 1970-01-01 02:00:00.000000000 +0200 --- enscript-1.6.5.1/states/hl/erlang.st.hilight 2010-05-20 15:28:08.148580599 +0200
+++ enscript-1.6.4/states/hl/erlang.st 2006-01-09 22:02:28.000000000 +0200 +++ enscript-1.6.5.1/states/hl/erlang.st 2010-05-20 15:28:08.148580599 +0200
@@ -0,0 +1,161 @@ @@ -0,0 +1,161 @@
+/** +/**
+ * Name: erlang + * Name: erlang
@ -491,9 +486,9 @@ diff -Nru enscript-1.6.4.orig/states/hl/erlang.st enscript-1.6.4/states/hl/erlan
+mode: erlang +mode: erlang
+End: +End:
+*/ +*/
diff -Nru enscript-1.6.4.orig/states/hl/forth.st enscript-1.6.4/states/hl/forth.st diff -up enscript-1.6.5.1/states/hl/forth.st.hilight enscript-1.6.5.1/states/hl/forth.st
--- enscript-1.6.4.orig/states/hl/forth.st 1970-01-01 02:00:00.000000000 +0200 --- enscript-1.6.5.1/states/hl/forth.st.hilight 2010-05-20 15:28:08.148580599 +0200
+++ enscript-1.6.4/states/hl/forth.st 2006-01-09 22:02:28.000000000 +0200 +++ enscript-1.6.5.1/states/hl/forth.st 2010-05-20 15:28:08.148580599 +0200
@@ -0,0 +1,96 @@ @@ -0,0 +1,96 @@
+/** +/**
+ * Name: forth + * Name: forth
@ -591,9 +586,9 @@ diff -Nru enscript-1.6.4.orig/states/hl/forth.st enscript-1.6.4/states/hl/forth.
+ } + }
+} +}
+ +
diff -Nru enscript-1.6.4.orig/states/hl/icon.st enscript-1.6.4/states/hl/icon.st diff -up enscript-1.6.5.1/states/hl/icon.st.hilight enscript-1.6.5.1/states/hl/icon.st
--- enscript-1.6.4.orig/states/hl/icon.st 1970-01-01 02:00:00.000000000 +0200 --- enscript-1.6.5.1/states/hl/icon.st.hilight 2010-05-20 15:28:08.148580599 +0200
+++ enscript-1.6.4/states/hl/icon.st 2006-01-09 22:02:28.000000000 +0200 +++ enscript-1.6.5.1/states/hl/icon.st 2010-05-20 15:28:08.148580599 +0200
@@ -0,0 +1,93 @@ @@ -0,0 +1,93 @@
+/** +/**
+ * Name: icon + * Name: icon
@ -688,9 +683,9 @@ diff -Nru enscript-1.6.4.orig/states/hl/icon.st enscript-1.6.4/states/hl/icon.st
+ language_print ($3); + language_print ($3);
+ } + }
+} +}
diff -Nru enscript-1.6.4.orig/states/hl/lua.st enscript-1.6.4/states/hl/lua.st diff -up enscript-1.6.5.1/states/hl/lua.st.hilight enscript-1.6.5.1/states/hl/lua.st
--- enscript-1.6.4.orig/states/hl/lua.st 1970-01-01 02:00:00.000000000 +0200 --- enscript-1.6.5.1/states/hl/lua.st.hilight 2010-05-20 15:28:08.148580599 +0200
+++ enscript-1.6.4/states/hl/lua.st 2006-01-09 22:02:28.000000000 +0200 +++ enscript-1.6.5.1/states/hl/lua.st 2010-05-20 15:28:08.148580599 +0200
@@ -0,0 +1,91 @@ @@ -0,0 +1,91 @@
+/** +/**
+ * Name: lua + * Name: lua
@ -783,10 +778,10 @@ diff -Nru enscript-1.6.4.orig/states/hl/lua.st enscript-1.6.4/states/hl/lua.st
+ } + }
+ +
+} +}
diff -Nru enscript-1.6.4.orig/states/hl/mail.st enscript-1.6.4/states/hl/mail.st diff -up enscript-1.6.5.1/states/hl/mail.st.hilight enscript-1.6.5.1/states/hl/mail.st
--- enscript-1.6.4.orig/states/hl/mail.st 2003-03-05 09:26:33.000000000 +0200 --- enscript-1.6.5.1/states/hl/mail.st.hilight 2009-01-24 21:59:34.000000000 +0100
+++ enscript-1.6.4/states/hl/mail.st 2006-01-09 22:02:28.000000000 +0200 +++ enscript-1.6.5.1/states/hl/mail.st 2010-05-20 15:28:08.148580599 +0200
@@ -27,7 +27,7 @@ @@ -27,7 +27,7 @@ state mail_header extends Highlight
END { END {
comment_face (true); comment_face (true);
} }
@ -795,10 +790,10 @@ diff -Nru enscript-1.6.4.orig/states/hl/mail.st enscript-1.6.4/states/hl/mail.st
language_print ($0); language_print ($0);
return; return;
} }
diff -Nru enscript-1.6.4.orig/states/hl/Makefile.am enscript-1.6.4/states/hl/Makefile.am diff -up enscript-1.6.5.1/states/hl/Makefile.am.hilight enscript-1.6.5.1/states/hl/Makefile.am
--- enscript-1.6.4.orig/states/hl/Makefile.am 2003-03-05 09:26:33.000000000 +0200 --- enscript-1.6.5.1/states/hl/Makefile.am.hilight 2010-03-06 13:59:56.000000000 +0100
+++ enscript-1.6.4/states/hl/Makefile.am 2006-01-09 22:06:23.000000000 +0200 +++ enscript-1.6.5.1/states/hl/Makefile.am 2010-05-20 15:29:46.656051228 +0200
@@ -38,7 +38,8 @@ @@ -36,9 +36,10 @@ idl.st inf.st java.st javascript.st ksh.
matlab.st nroff.st objc.st outline.st pascal.st passthrough.st perl.st \ matlab.st nroff.st objc.st outline.st pascal.st passthrough.st perl.st \
postscript.st python.st pyrex.st rfc.st scheme.st sh.st skill.st \ postscript.st python.st pyrex.st rfc.st scheme.st sh.st skill.st \
sql.st states.st synopsys.st tcl.st tcsh.st tex.st vba.st verilog.st \ sql.st states.st synopsys.st tcl.st tcsh.st tex.st vba.st verilog.st \
@ -806,24 +801,15 @@ diff -Nru enscript-1.6.4.orig/states/hl/Makefile.am enscript-1.6.4/states/hl/Mak
+vhdl.st vrml.st wmlscript.st zsh.st eiffel.st erlang.st dylan.st oz.st \ +vhdl.st vrml.st wmlscript.st zsh.st eiffel.st erlang.st dylan.st oz.st \
+lua.st oberon2.st icon.st smalltalk.st forth.st sml.st php.st ruby.st +lua.st oberon2.st icon.st smalltalk.st forth.st sml.st php.st ruby.st
states = $(misc) $(styles) $(languages) $(highlightings) hldir = $(pkgdatadir)/hl
dist_hl_DATA = $(misc) $(styles) $(languages) $(highlightings)
diff -Nru enscript-1.6.4.orig/states/hl/Makefile.in enscript-1.6.4/states/hl/Makefile.in -EXTRA_DIST = ChangeLog.old
--- enscript-1.6.4.orig/states/hl/Makefile.in 2003-03-05 09:40:07.000000000 +0200 \ No newline at end of file
+++ enscript-1.6.4/states/hl/Makefile.in 2006-01-09 22:05:26.000000000 +0200 +EXTRA_DIST = ChangeLog.old
@@ -188,7 +188,8 @@ diff -up enscript-1.6.5.1/states/hl/oberon2.st.hilight enscript-1.6.5.1/states/hl/oberon2.st
matlab.st nroff.st objc.st outline.st pascal.st passthrough.st perl.st \ --- enscript-1.6.5.1/states/hl/oberon2.st.hilight 2010-05-20 15:28:08.148580599 +0200
postscript.st python.st pyrex.st rfc.st scheme.st sh.st skill.st \ +++ enscript-1.6.5.1/states/hl/oberon2.st 2010-05-20 15:28:08.148580599 +0200
sql.st states.st synopsys.st tcl.st tcsh.st tex.st vba.st verilog.st \
-vhdl.st vrml.st wmlscript.st zsh.st
+vhdl.st vrml.st wmlscript.st zsh.st eiffel.st erlang.st dylan.st oz.st \
+lua.st oberon2.st icon.st smalltalk.st forth.st sml.st php.st ruby.st
states = $(misc) $(styles) $(languages) $(highlightings)
diff -Nru enscript-1.6.4.orig/states/hl/oberon2.st enscript-1.6.4/states/hl/oberon2.st
--- enscript-1.6.4.orig/states/hl/oberon2.st 1970-01-01 02:00:00.000000000 +0200
+++ enscript-1.6.4/states/hl/oberon2.st 2006-01-09 22:02:28.000000000 +0200
@@ -0,0 +1,111 @@ @@ -0,0 +1,111 @@
+/** +/**
+ * Name: oberon2 + * Name: oberon2
@ -936,9 +922,9 @@ diff -Nru enscript-1.6.4.orig/states/hl/oberon2.st enscript-1.6.4/states/hl/ober
+ language_print ($3); + language_print ($3);
+ } + }
+} +}
diff -Nru enscript-1.6.4.orig/states/hl/oz.st enscript-1.6.4/states/hl/oz.st diff -up enscript-1.6.5.1/states/hl/oz.st.hilight enscript-1.6.5.1/states/hl/oz.st
--- enscript-1.6.4.orig/states/hl/oz.st 1970-01-01 02:00:00.000000000 +0200 --- enscript-1.6.5.1/states/hl/oz.st.hilight 2010-05-20 15:28:08.148580599 +0200
+++ enscript-1.6.4/states/hl/oz.st 2006-01-09 22:02:28.000000000 +0200 +++ enscript-1.6.5.1/states/hl/oz.st 2010-05-20 15:28:08.148580599 +0200
@@ -0,0 +1,89 @@ @@ -0,0 +1,89 @@
+/** +/**
+ * Name: oz + * Name: oz
@ -1029,10 +1015,10 @@ diff -Nru enscript-1.6.4.orig/states/hl/oz.st enscript-1.6.4/states/hl/oz.st
+ } + }
+ +
+} +}
diff -Nru enscript-1.6.4.orig/states/hl/perl.st enscript-1.6.4/states/hl/perl.st diff -up enscript-1.6.5.1/states/hl/perl.st.hilight enscript-1.6.5.1/states/hl/perl.st
--- enscript-1.6.4.orig/states/hl/perl.st 2003-03-05 09:32:09.000000000 +0200 --- enscript-1.6.5.1/states/hl/perl.st.hilight 2009-01-24 21:59:34.000000000 +0100
+++ enscript-1.6.4/states/hl/perl.st 2006-01-09 22:02:28.000000000 +0200 +++ enscript-1.6.5.1/states/hl/perl.st 2010-05-20 15:28:08.148580599 +0200
@@ -60,6 +60,11 @@ @@ -60,6 +60,11 @@ state perl_bquot_string extends Highligh
state perl extends HighlightEntry state perl extends HighlightEntry
{ {
@ -1044,7 +1030,7 @@ diff -Nru enscript-1.6.4.orig/states/hl/perl.st enscript-1.6.4/states/hl/perl.st
/* Comments. */ /* Comments. */
/#.*$/ { /#.*$/ {
comment_face (true); comment_face (true);
@@ -127,7 +132,6 @@ @@ -127,7 +132,6 @@ state perl extends HighlightEntry
/* Variables */ /* Variables */
/[$%@&]+\w+/ { /[$%@&]+\w+/ {
@ -1052,9 +1038,9 @@ diff -Nru enscript-1.6.4.orig/states/hl/perl.st enscript-1.6.4/states/hl/perl.st
language_print ($0); language_print ($0);
} }
diff -Nru enscript-1.6.4.orig/states/hl/smalltalk.st enscript-1.6.4/states/hl/smalltalk.st diff -up enscript-1.6.5.1/states/hl/smalltalk.st.hilight enscript-1.6.5.1/states/hl/smalltalk.st
--- enscript-1.6.4.orig/states/hl/smalltalk.st 1970-01-01 02:00:00.000000000 +0200 --- enscript-1.6.5.1/states/hl/smalltalk.st.hilight 2010-05-20 15:28:08.148580599 +0200
+++ enscript-1.6.4/states/hl/smalltalk.st 2006-01-09 22:02:28.000000000 +0200 +++ enscript-1.6.5.1/states/hl/smalltalk.st 2010-05-20 15:28:08.148580599 +0200
@@ -0,0 +1,80 @@ @@ -0,0 +1,80 @@
+/** +/**
+ * Name: Smalltalk + * Name: Smalltalk
@ -1136,9 +1122,9 @@ diff -Nru enscript-1.6.4.orig/states/hl/smalltalk.st enscript-1.6.4/states/hl/sm
+ } + }
+ +
+} +}
diff -Nru enscript-1.6.4.orig/states/hl/sml.st enscript-1.6.4/states/hl/sml.st diff -up enscript-1.6.5.1/states/hl/sml.st.hilight enscript-1.6.5.1/states/hl/sml.st
--- enscript-1.6.4.orig/states/hl/sml.st 1970-01-01 02:00:00.000000000 +0200 --- enscript-1.6.5.1/states/hl/sml.st.hilight 2010-05-20 15:28:08.148580599 +0200
+++ enscript-1.6.4/states/hl/sml.st 2006-01-09 22:02:28.000000000 +0200 +++ enscript-1.6.5.1/states/hl/sml.st 2010-05-20 15:28:08.148580599 +0200
@@ -0,0 +1,101 @@ @@ -0,0 +1,101 @@
+/** +/**
+ * Name: sml + * Name: sml
@ -1241,10 +1227,10 @@ diff -Nru enscript-1.6.4.orig/states/hl/sml.st enscript-1.6.4/states/hl/sml.st
+ } + }
+ +
+} +}
diff -Nru enscript-1.6.4.orig/states/hl/tcl.st enscript-1.6.4/states/hl/tcl.st diff -up enscript-1.6.5.1/states/hl/tcl.st.hilight enscript-1.6.5.1/states/hl/tcl.st
--- enscript-1.6.4.orig/states/hl/tcl.st 2003-03-05 09:26:33.000000000 +0200 --- enscript-1.6.5.1/states/hl/tcl.st.hilight 2009-01-24 21:59:34.000000000 +0100
+++ enscript-1.6.4/states/hl/tcl.st 2006-01-09 22:02:28.000000000 +0200 +++ enscript-1.6.5.1/states/hl/tcl.st 2010-05-20 15:28:08.148580599 +0200
@@ -128,7 +128,7 @@ @@ -128,7 +128,7 @@ state tcl extends HighlightEntry
|e(ntry|of|rror|v(al|ent)|x(ec|it|pr))\ |e(ntry|of|rror|v(al|ent)|x(ec|it|pr))\
|f(blocked|configure|ile(|event|name)|lush|o(cus|nt|r(|each|mat))|rame)\ |f(blocked|configure|ile(|event|name)|lush|o(cus|nt|r(|each|mat))|rame)\
|g(ets|lob(|al)|r(ab|id))|history|i(f|mage|n(cr|fo|terp))|join\ |g(ets|lob(|al)|r(ab|id))|history|i(f|mage|n(cr|fo|terp))|join\

View File

@ -1,90 +0,0 @@
--- src/psgen.c
+++ src/psgen.c 2008-10-29 10:43:08.512598143 +0100
@@ -24,6 +24,7 @@
* Boston, MA 02111-1307, USA.
*/
+#include <limits.h>
#include "gsint.h"
/*
@@ -124,7 +125,7 @@ struct gs_token_st
double xscale;
double yscale;
int llx, lly, urx, ury; /* Bounding box. */
- char filename[512];
+ char filename[PATH_MAX];
char *skipbuf;
unsigned int skipbuf_len;
unsigned int skipbuf_pos;
@@ -135,11 +136,11 @@ struct gs_token_st
Color bgcolor;
struct
{
- char name[512];
+ char name[PATH_MAX];
FontPoint size;
InputEncoding encoding;
} font;
- char filename[512];
+ char filename[PATH_MAX];
} u;
};
@@ -248,7 +249,7 @@ static int do_print = 1;
static int user_fontp = 0;
/* The user ^@font{}-defined font. */
-static char user_font_name[256];
+static char user_font_name[PATH_MAX];
static FontPoint user_font_pt;
static InputEncoding user_font_encoding;
@@ -978,7 +979,8 @@ large for page\n"),
FATAL ((stderr,
_("user font encoding can be only the system's default or `ps'")));
- strcpy (user_font_name, token.u.font.name);
+ memset (user_font_name, 0, sizeof(user_font_name));
+ strncpy (user_font_name, token.u.font.name, sizeof(user_font_name) - 1);
user_font_pt.w = token.u.font.size.w;
user_font_pt.h = token.u.font.size.h;
user_font_encoding = token.u.font.encoding;
@@ -1444,7 +1446,7 @@ read_special_escape (InputStream *is, To
buf[i] = ch;
if (i + 1 >= sizeof (buf))
FATAL ((stderr, _("too long argument for %s escape:\n%.*s"),
- escapes[i].name, i, buf));
+ escapes[e].name, i, buf));
}
buf[i] = '\0';
@@ -1452,7 +1454,8 @@ read_special_escape (InputStream *is, To
switch (escapes[e].escape)
{
case ESC_FONT:
- strcpy (token->u.font.name, buf);
+ memset (token->u.font.name, 0, sizeof(token->u.font.name));
+ strncpy (token->u.font.name, buf, sizeof(token->u.font.name) - 1);
/* Check for the default font. */
if (strcmp (token->u.font.name, "default") == 0)
@@ -1465,7 +1468,8 @@ read_special_escape (InputStream *is, To
FATAL ((stderr, _("malformed font spec for ^@font escape: %s"),
token->u.font.name));
- strcpy (token->u.font.name, cp);
+ memset (token->u.font.name, 0, sizeof(token->u.font.name));
+ strncpy (token->u.font.name, cp, sizeof(token->u.font.name) - 1);
xfree (cp);
}
token->type = tFONT;
@@ -1544,7 +1548,8 @@ read_special_escape (InputStream *is, To
break;
case ESC_SETFILENAME:
- strcpy (token->u.filename, buf);
+ memset (token->u.filename, 0, sizeof(token->u.font.name));
+ strncpy (token->u.filename, buf, sizeof(token->u.filename) - 1);
token->type = tSETFILENAME;
break;

View File

@ -1,15 +0,0 @@
diff -up enscript-1.6.4/src/main.c.doublefree enscript-1.6.4/src/main.c
--- enscript-1.6.4/src/main.c.doublefree 2008-08-08 11:10:07.000000000 +0200
+++ enscript-1.6.4/src/main.c 2008-08-08 11:11:51.000000000 +0200
@@ -1714,8 +1714,9 @@ name width\theight\tllx\tlly
is_close (&is);
}
- /* Clean up toc file. */
- fclose (toc_fp);
+ else
+ /* Clean up toc file. */
+ fclose (toc_fp);
}
/* Give trailer a chance to dump itself. */

View File

@ -1,31 +1,24 @@
diff -up enscript-1.6.4/afm/Makefile.am.rh477382 enscript-1.6.4/afm/Makefile.am diff -up enscript-1.6.5.1/afm/Makefile.am.rh477382 enscript-1.6.5.1/afm/Makefile.am
--- enscript-1.6.4/afm/Makefile.am.rh477382 2009-11-30 14:26:54.520478161 +0100 --- enscript-1.6.5.1/afm/Makefile.am.rh477382 2010-03-06 14:02:53.000000000 +0100
+++ enscript-1.6.4/afm/Makefile.am 2009-11-30 14:29:12.937976060 +0100 +++ enscript-1.6.5.1/afm/Makefile.am 2010-05-21 13:09:28.000346827 +0200
@@ -31,11 +31,11 @@ hvnbo.afm hvno.afm hvo.afm ncb.afm ncbi. @@ -29,9 +29,12 @@ hvnbo.afm hvno.afm hvo.afm ncb.afm ncbi.
pobi.afm poi.afm por.afm sy.afm tib.afm tibi.afm tii.afm tir.afm \ pobi.afm poi.afm por.afm sy.afm tib.afm tibi.afm tii.afm tir.afm \
zcmi.afm zd.afm zcmi.afm zd.afm
-public_fonts = matrix.afm matrix.pfa -public_fonts = matrix.afm matrix.pfa
+public_fonts = matrix.afm matrix.eps +public_fonts = matrix.afm matrix.eps
EXTRA_DIST = font.map $(default_afm) $(public_fonts) afmdir = $(pkgdatadir)/afm
dist_afm_DATA = font.map $(default_afm) $(public_fonts)
-install-data-local: EXTRA_DIST = ChangeLog.old
+install-data-local: $(EXTRA_DIST)
$(top_srcdir)/mkinstalldirs $(DESTDIR)/$(datadir)/enscript
$(top_srcdir)/mkinstalldirs $(DESTDIR)/$(datadir)/enscript/afm
for f in $(EXTRA_DIST); do \
@@ -44,3 +44,6 @@ install-data-local:
uninstall-local:
rm -rf $(DESTDIR)/$(datadir)/enscript/afm
+ +
+matrix.eps: matrix.pfa +matrix.eps: matrix.pfa
+ mv matrix.pfa matrix.eps + cp matrix.pfa matrix.eps
diff -up enscript-1.6.4/src/util.c.rh477382 enscript-1.6.4/src/util.c diff -up enscript-1.6.5.1/src/util.c.rh477382 enscript-1.6.5.1/src/util.c
--- enscript-1.6.4/src/util.c.rh477382 2003-03-05 08:26:32.000000000 +0100 --- enscript-1.6.5.1/src/util.c.rh477382 2009-12-28 00:57:12.000000000 +0100
+++ enscript-1.6.4/src/util.c 2009-11-30 14:26:54.550489123 +0100 +++ enscript-1.6.5.1/src/util.c 2010-05-21 13:08:10.920347803 +0200
@@ -1081,9 +1081,16 @@ download_font (char *name) @@ -1079,9 +1079,16 @@ download_font (char *name)
buffer_append (&fname, ".pfb"); buffer_append (&fname, ".pfb");
if (stat (buffer_ptr (&fname), &stat_st) != 0) if (stat (buffer_ptr (&fname), &stat_st) != 0)
{ {

View File

@ -1,104 +1,33 @@
--- enscript-1.6.1/lib/simple.hdr.wrap_header 1997-03-03 09:00:08.000000000 +0100 diff -up enscript-1.6.5.1/lib/simple.hdr.wrap_header enscript-1.6.5.1/lib/simple.hdr
+++ enscript-1.6.1/lib/simple.hdr 2007-02-12 12:57:02.000000000 +0100 --- enscript-1.6.5.1/lib/simple.hdr.wrap_header 2009-01-24 21:59:34.000000000 +0100
@@ -1,50 +1,68 @@ +++ enscript-1.6.5.1/lib/simple.hdr 2010-05-21 13:04:28.070346832 +0200
-% @@ -3,6 +3,10 @@
-% Default simple header. % Copyright (c) 1995 Markku Rossi.
-% Copyright (c) 1995 Markku Rossi. % Author: Markku Rossi <mtr@iki.fi>
-% Author: Markku Rossi <mtr@iki.fi> %
-%
-
-%
-% This file is part of GNU enscript.
-%
-% This program is free software; you can redistribute it and/or modify
-% it under the terms of the GNU General Public License as published by
-% the Free Software Foundation; either version 2, or (at your option)
-% any later version.
-%
-% This program is distributed in the hope that it will be useful,
-% but WITHOUT ANY WARRANTY; without even the implied warranty of
-% MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-% GNU General Public License for more details.
-%
-% You should have received a copy of the GNU General Public License
-% along with this program; see the file COPYING. If not, write to
-% the Free Software Foundation, 59 Temple Place - Suite 330,
-% Boston, MA 02111-1307, USA.
-%
-
-% -- code follows this line --
-%Format: fmodstr $D{%a %b %d %H:%M:%S %Y}
-%Format: pagenumstr $V$%
-
-/do_header { % print default simple header
- gsave
- d_header_x d_header_y HFpt_h 3 div add translate
-
- HF setfont
- user_header_p {
- 5 0 moveto user_header_left_str show
-
- d_header_w user_header_center_str stringwidth pop sub 2 div
- 0 moveto user_header_center_str show
-
- d_header_w user_header_right_str stringwidth pop sub 5 sub
- 0 moveto user_header_right_str show
- } {
- 5 0 moveto fname show
- 45 0 rmoveto fmodstr show
- 45 0 rmoveto pagenumstr show
- } ifelse
-
- grestore
-} def
+%
+% Default simple header.
+% Copyright (c) 1995 Markku Rossi.
+% Author: Markku Rossi <mtr@iki.fi>
+%
+% Modified: Chris Josefy, USA, MAY 2006 +% Modified: Chris Josefy, USA, MAY 2006
+% + Added line wrapping to header to work more like AIX enscript +% + Added line wrapping to header to work more like AIX enscript
+% + This assumes that one does not change the header font size from the default +% + This assumes that one does not change the header font size from the default
+% + This also assumes that the line only wraps once +% + This also assumes that the line only wraps once
+
+% %
+% This file is part of GNU enscript. % This file is part of GNU Enscript.
+% @@ -24,6 +28,7 @@
+% This program is free software; you can redistribute it and/or modify % -- code follows this line --
+% it under the terms of the GNU General Public License as published by %Format: fmodstr $D{%a %b %d %H:%M:%S %Y}
+% the Free Software Foundation; either version 2, or (at your option) %Format: pagenumstr $V$%
+% any later version.
+%
+% This program is distributed in the hope that it will be useful,
+% but WITHOUT ANY WARRANTY; without even the implied warranty of
+% MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+% GNU General Public License for more details.
+%
+% You should have received a copy of the GNU General Public License
+% along with this program; see the file COPYING. If not, write to
+% the Free Software Foundation, 59 Temple Place - Suite 330,
+% Boston, MA 02111-1307, USA.
+%
+
+% -- code follows this line --
+%Format: fmodstr $D{%a %b %d %H:%M:%S %Y}
+%Format: pagenumstr $V$%
+%HeaderHeight: 44 +%HeaderHeight: 44
+
+/do_header { % print default simple header /do_header { % print default simple header
+ gsave gsave
+ d_header_x d_header_y HFpt_h 3 div add translate @@ -39,10 +44,23 @@
+ d_header_w user_header_right_str stringwidth pop sub 5 sub
+ HF setfont 0 moveto user_header_right_str show
+ user_header_p { } {
+ 5 0 moveto user_header_left_str show - 5 0 moveto fname show
+ - 45 0 rmoveto fmodstr show
+ d_header_w user_header_center_str stringwidth pop sub 2 div - 45 0 rmoveto pagenumstr show
+ 0 moveto user_header_center_str show - } ifelse
+
+ d_header_w user_header_right_str stringwidth pop sub 5 sub
+ 0 moveto user_header_right_str show
+ } {
+ fname length fmodstr length add pagenumstr length add 95 6 idiv add d_header_w 6 idiv le{ + fname length fmodstr length add pagenumstr length add 95 6 idiv add d_header_w 6 idiv le{
+ 5 0 moveto fname show + 5 0 moveto fname show
+ 45 0 rmoveto fmodstr show + 45 0 rmoveto fmodstr show
@ -116,6 +45,6 @@
+ fname fname length d_header_w 6 idiv idiv d_header_w 6 idiv mul dup fname length exch sub getinterval show + fname fname length d_header_w 6 idiv idiv d_header_w 6 idiv mul dup fname length exch sub getinterval show
+ }ifelse + }ifelse
+ }ifelse + }ifelse
+
+ grestore grestore
+} def } def

View File

@ -1,8 +1,8 @@
Summary: A plain ASCII to PostScript converter Summary: A plain ASCII to PostScript converter
Name: enscript Name: enscript
Version: 1.6.4 Version: 1.6.5.1
Release: 16%{?dist} Release: 1%{?dist}
License: GPLv2+ License: GPLv3+
Group: Applications/Publishing Group: Applications/Publishing
URL: http://www.gnu.org/software/enscript URL: http://www.gnu.org/software/enscript
# Tarball exists nowhere. You have to obtain it via: # Tarball exists nowhere. You have to obtain it via:
@ -14,24 +14,16 @@ Source1: enscript-ruby-1.6.4.tar.gz
Source2: enscript-php-1.6.4.st Source2: enscript-php-1.6.4.st
#http://home.raxnet.net/downloads/viewcvs/php.st #http://home.raxnet.net/downloads/viewcvs/php.st
# Make `make DESTDIR=dir install` working
Patch0: enscript-1.6.1-config.patch
# RH #177336 # RH #177336
Patch1: enscript-1.6.4-hilight.patch Patch1: enscript-1.6.4-hilight.patch
# RH #61294 # RH #61294
Patch3: enscript-1.6.1-locale.patch Patch3: enscript-1.6.1-locale.patch
# RH #132964
Patch4: enscript-doublefree.patch
Patch6: enscript-1.6.1-CAN-2004-1185.patch
Patch7: enscript-1.6.1-CAN-2004-1186.patch
# RH #224548 # RH #224548
Patch8: enscript-wrap_header.patch Patch8: enscript-wrap_header.patch
Patch9: enscript-1.6.4-rh457719.patch Patch9: enscript-1.6.4-rh457719.patch
Patch10:enscript-1.6.4-rh457720.patch Patch10:enscript-1.6.4-rh457720.patch
Patch11:enscript-CVE-2008-3863+CVE-2008-4306.patch
Patch12:enscript-rh477382.patch Patch12:enscript-rh477382.patch
Requires(preun): /sbin/install-info Requires(preun): /sbin/install-info
Requires(post): /sbin/install-info Requires(post): /sbin/install-info
@ -50,16 +42,11 @@ includes many options for customizing printouts
%prep %prep
%setup -q %setup -q
%patch0 -p1 -b .config
%patch1 -p1 -b .hilight %patch1 -p1 -b .hilight
%patch3 -p1 -b .locale %patch3 -p1 -b .locale
%patch4 -p1 -b .doublefree
%patch6 -p1 -b .CAN-2004-1185
%patch7 -p1 -b .CAN-2004-1186
%patch8 -p1 -b .wrap_header %patch8 -p1 -b .wrap_header
%patch9 -p1 -b .rh457719 %patch9 -p1 -b .rh457719
%patch10 -p1 -b .rh457720 %patch10 -p1 -b .rh457720
%patch11 -p0 -b .CVE-2008-3863+CVE-2008-4306
%patch12 -p1 -b .rh477382 %patch12 -p1 -b .rh477382
%{__tar} -C states/hl -zxf %{SOURCE1} ruby.st %{__tar} -C states/hl -zxf %{SOURCE1} ruby.st
@ -121,6 +108,16 @@ fi
%config(noreplace) %{_sysconfdir}/enscript.cfg %config(noreplace) %{_sysconfdir}/enscript.cfg
%changelog %changelog
* Thu May 20 2010 Adam Tkac <atkac redhat com> - 1.6.5.1-1
- update to 1.6.5.1
- patches merged
- enscript-1.6.1-config.patch
- enscript-doublefree.patch
- enscript-1.6.1-CAN-2004-1185.patch
- enscript-1.6.1-CAN-2004-1186.patch
- enscript-CVE-2008-3863+CVE-2008-4306.patch
- license changed to GPLv3+
* Mon Dec 14 2009 Adam Tkac <atkac redhat com> - 1.6.4-16 * Mon Dec 14 2009 Adam Tkac <atkac redhat com> - 1.6.4-16
- merge review related fixes (#225729) - merge review related fixes (#225729)

View File

@ -1,3 +1,3 @@
b5174b59e4a050fb462af5dbf28ebba3 enscript-1.6.4.tar.gz
fa9c837b2a258716411f6df827d36eb3 enscript-ruby-1.6.4.tar.gz
f3a0083638ac3fddc493d44b6515182a enscript-php-1.6.4.st f3a0083638ac3fddc493d44b6515182a enscript-php-1.6.4.st
fa9c837b2a258716411f6df827d36eb3 enscript-ruby-1.6.4.tar.gz
2d9568800bfa2831c82b6e216adaad78 enscript-1.6.5.1.tar.gz