groff/groff-1.18.1.1-destbufferoverflow.patch
Michal Vyskocil db3c1eeedd Accepting request 22399 from home:mvyskocil:branches:M17N
Copy from home:mvyskocil:branches:M17N/groff via accept of submit request 22399 revision 3.
Request was accepted with message:
OK

OBS-URL: https://build.opensuse.org/request/show/22399
OBS-URL: https://build.opensuse.org/package/show/M17N/groff?expand=0&rev=4
2009-10-14 13:55:47 +00:00

14 lines
584 B
Diff

Index: src/devices/grops/ps.cc
===================================================================
--- src/devices/grops/ps.cc.orig 2002-06-19 23:07:33.000000000 +0200
+++ src/devices/grops/ps.cc 2008-10-07 23:57:44.000000000 +0200
@@ -739,7 +739,7 @@ void ps_printer::encode_fonts()
{
if (next_encoding_index == 0)
return;
- char *done_encoding = new char[next_encoding_index];
+ char *done_encoding = new char[next_encoding_index +1];
for (int i = 0; i < next_encoding_index; i++)
done_encoding[i] = 0;
for (font_pointer_list *f = font_list; f; f = f->next) {