2000-02-03 Lars Gullik Bjønnes <larsbj@lyx.org>
+ * src/lyxrow.h: make sure that all Row variables are initialized.
+
+ * src/text2.C (TextHandleUndo): comment out a delete, this might
+ introduce a memory leak, but should also help us to not try to
+ read freed memory. We need to look at this one.
+
* src/paragraph.C (SimpleDocBookOneTablePar): initialize column to 0
(LyXParagraph): initalize footnotekind.
///
struct Row {
///
+ Row()
+ : par(0), pos(0), baseline(0), fill(0), height(0),
+ ascent_of_text(0), next(0), previous(0)
+ {}
+ ///
LyXParagraph * par;
///
LyXParagraph::size_type pos;
if (undo->kind == Undo::EDIT){
tmppar2->text = tmppar->text;
tmppar->text.clear();
- //tmppar->text.erase(tmppar->text.begin(),
- // tmppar->text.end());
tmppar2 = tmppar2->next;
}
if ( currentrow && currentrow->par == tmppar )
currentrow = currentrow -> previous;
- delete tmppar;
+ // Commenting out this might remove the error
+ // reported by Purify, but it might also
+ // introduce a memory leak. We need to
+ // check this (Lgb)
+ //delete tmppar;
}
}