bug-groff
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

groff 1.18.1 memory allocation bugs


From: Ivan Popov
Subject: groff 1.18.1 memory allocation bugs
Date: Sun, 30 Mar 2003 03:00:52 +0200 (MET DST)

Hello,

I have identified a couple of places in groff where it is doing
wrong things with memory allocation.

There are probably more places there, but I can't spend more time on
reading the source, neither am I good at C++.

I attach the patch that enables me compile and use groff with
gcc 3.2.2 and corresponding libstdc++. Without the patch groff and
pre-grohtml segfault. With the patch they do not segfault at once at
least.

The patch is not "right", but it can show the problem and a
possible fix. In new.cc one should redefine either both
new and delete, or none of them, imho. I do not know how to do it right.
Likewise usage of malloc() and then delete on the same object is
unacceptable.

Best regards,
--
Ivan

Attachment: patch.new.cc-no-new
Description: Text document

Attachment: patch.pre-html.cc.malloc-delete
Description: Text document


reply via email to

[Prev in Thread] Current Thread [Next in Thread]