stop segfault in FormPreferences::feedback; real fix will involve thinking about what feedbackObj should be set to at all times

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@1202 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
Allan Rae 2000-11-07 06:41:13 +00:00
parent f29feefd79
commit 890f5feda6
18 changed files with 70 additions and 53 deletions

View File

@ -1,3 +1,12 @@
2000-11-07 Allan Rae <rae@lyx.org>
* src/frontends/xforms/FormPreferences.C (feedback): make sure
ob isn't 0 before using it. See comments in function.
* src/frontends/xforms/forms/fdfixc.sed: tiny spacing fix.
* src/frontends/xforms/form_*.C: regenerated
2000-11-07 Lars Gullik Bjønnes <larsbj@lyx.org>
* src/LaTeX.C (deplog): change reg1 to handle (/.../.../fil.sty)

View File

@ -47,35 +47,35 @@ src/frontends/kde/refdlg.C
src/frontends/kde/tocdlg.C
src/frontends/kde/urldlg.C
src/frontends/xforms/FormBase.h
src/frontends/xforms/form_citation.C
src/frontends/xforms/FormCitation.C
src/frontends/xforms/form_copyright.C
src/frontends/xforms/form_citation.C
src/frontends/xforms/FormCopyright.C
src/frontends/xforms/form_document.C
src/frontends/xforms/form_copyright.C
src/frontends/xforms/FormDocument.C
src/frontends/xforms/form_error.C
src/frontends/xforms/form_document.C
src/frontends/xforms/FormError.C
src/frontends/xforms/form_graphics.C
src/frontends/xforms/form_error.C
src/frontends/xforms/FormGraphics.C
src/frontends/xforms/form_index.C
src/frontends/xforms/form_graphics.C
src/frontends/xforms/FormIndex.C
src/frontends/xforms/form_index.C
src/frontends/xforms/FormInset.h
src/frontends/xforms/form_paragraph.C
src/frontends/xforms/FormParagraph.C
src/frontends/xforms/form_preferences.C
src/frontends/xforms/form_paragraph.C
src/frontends/xforms/FormPreferences.C
src/frontends/xforms/form_print.C
src/frontends/xforms/form_preferences.C
src/frontends/xforms/FormPrint.C
src/frontends/xforms/form_ref.C
src/frontends/xforms/form_print.C
src/frontends/xforms/FormRef.C
src/frontends/xforms/form_tabular.C
src/frontends/xforms/form_ref.C
src/frontends/xforms/FormTabular.C
src/frontends/xforms/form_tabular_create.C
src/frontends/xforms/form_tabular.C
src/frontends/xforms/FormTabularCreate.C
src/frontends/xforms/form_toc.C
src/frontends/xforms/form_tabular_create.C
src/frontends/xforms/FormToc.C
src/frontends/xforms/form_url.C
src/frontends/xforms/form_toc.C
src/frontends/xforms/FormUrl.C
src/frontends/xforms/form_url.C
src/frontends/xforms/Menubar_pimpl.C
src/gettext.h
src/importer.C

View File

@ -261,6 +261,14 @@ void FormPreferences::apply()
void FormPreferences::feedback( FL_OBJECT * ob )
{
// Angus, do you really want to allow ob to be 0?
// You set this in feedbackPost. Why?
if (!ob) return; // stop a segfault below.
// an alternative to the above is to check feedbackObj in
// FeedbackCB and not call this function at all. But that's a
// matter of deciding who should be checking the parameters for this
// function.
string str;
if (ob->form->fdui == colours_) {

View File

@ -12,7 +12,7 @@
FD_form_citation::~FD_form_citation()
{
if (form->visible ) fl_hide_form( form );
if ( form->visible ) fl_hide_form( form );
fl_free_form( form );
}

View File

@ -12,7 +12,7 @@
FD_form_copyright::~FD_form_copyright()
{
if (form->visible ) fl_hide_form( form );
if ( form->visible ) fl_hide_form( form );
fl_free_form( form );
}

View File

@ -14,7 +14,7 @@
FD_form_tabbed_document::~FD_form_tabbed_document()
{
if (form->visible ) fl_hide_form( form );
if ( form->visible ) fl_hide_form( form );
fl_free_form( form );
}
@ -56,7 +56,7 @@ FD_form_tabbed_document * FormDocument::build_tabbed_document()
FD_form_doc_paper::~FD_form_doc_paper()
{
if (form->visible ) fl_hide_form( form );
if ( form->visible ) fl_hide_form( form );
fl_free_form( form );
}
@ -177,7 +177,7 @@ FD_form_doc_paper * FormDocument::build_doc_paper()
FD_form_doc_class::~FD_form_doc_class()
{
if (form->visible ) fl_hide_form( form );
if ( form->visible ) fl_hide_form( form );
fl_free_form( form );
}
@ -286,7 +286,7 @@ FD_form_doc_class * FormDocument::build_doc_class()
FD_form_doc_language::~FD_form_doc_language()
{
if (form->visible ) fl_hide_form( form );
if ( form->visible ) fl_hide_form( form );
fl_free_form( form );
}
@ -336,7 +336,7 @@ FD_form_doc_language * FormDocument::build_doc_language()
FD_form_doc_options::~FD_form_doc_options()
{
if (form->visible ) fl_hide_form( form );
if ( form->visible ) fl_hide_form( form );
fl_free_form( form );
}
@ -380,7 +380,7 @@ FD_form_doc_options * FormDocument::build_doc_options()
FD_form_doc_bullet::~FD_form_doc_bullet()
{
if (form->visible ) fl_hide_form( form );
if ( form->visible ) fl_hide_form( form );
fl_free_form( form );
}

View File

@ -12,7 +12,7 @@
FD_form_error::~FD_form_error()
{
if (form->visible ) fl_hide_form( form );
if ( form->visible ) fl_hide_form( form );
fl_free_form( form );
}

View File

@ -12,7 +12,7 @@
FD_form_graphics::~FD_form_graphics()
{
if (form->visible ) fl_hide_form( form );
if ( form->visible ) fl_hide_form( form );
fl_free_form( form );
}

View File

@ -12,7 +12,7 @@
FD_form_index::~FD_form_index()
{
if (form->visible ) fl_hide_form( form );
if ( form->visible ) fl_hide_form( form );
fl_free_form( form );
}

View File

@ -12,7 +12,7 @@
FD_form_paragraph_general::~FD_form_paragraph_general()
{
if (form->visible ) fl_hide_form( form );
if ( form->visible ) fl_hide_form( form );
fl_free_form( form );
}
@ -136,7 +136,7 @@ FD_form_paragraph_general * FormParagraph::build_paragraph_general()
FD_form_paragraph_extra::~FD_form_paragraph_extra()
{
if (form->visible ) fl_hide_form( form );
if ( form->visible ) fl_hide_form( form );
fl_free_form( form );
}
@ -225,7 +225,7 @@ FD_form_paragraph_extra * FormParagraph::build_paragraph_extra()
FD_form_tabbed_paragraph::~FD_form_tabbed_paragraph()
{
if (form->visible ) fl_hide_form( form );
if ( form->visible ) fl_hide_form( form );
fl_free_form( form );
}

View File

@ -12,7 +12,7 @@
FD_form_preferences::~FD_form_preferences()
{
if (form->visible ) fl_hide_form( form );
if ( form->visible ) fl_hide_form( form );
fl_free_form( form );
}
@ -57,7 +57,7 @@ FD_form_preferences * FormPreferences::build_preferences()
FD_form_outer_tab::~FD_form_outer_tab()
{
if (form->visible ) fl_hide_form( form );
if ( form->visible ) fl_hide_form( form );
fl_free_form( form );
}
@ -83,7 +83,7 @@ FD_form_outer_tab * FormPreferences::build_outer_tab()
FD_form_screen_fonts::~FD_form_screen_fonts()
{
if (form->visible ) fl_hide_form( form );
if ( form->visible ) fl_hide_form( form );
fl_free_form( form );
}
@ -171,7 +171,7 @@ FD_form_screen_fonts * FormPreferences::build_screen_fonts()
FD_form_outputs_misc::~FD_form_outputs_misc()
{
if (form->visible ) fl_hide_form( form );
if ( form->visible ) fl_hide_form( form );
fl_free_form( form );
}
@ -223,7 +223,7 @@ FD_form_outputs_misc * FormPreferences::build_outputs_misc()
FD_form_spellchecker::~FD_form_spellchecker()
{
if (form->visible ) fl_hide_form( form );
if ( form->visible ) fl_hide_form( form );
fl_free_form( form );
}
@ -287,7 +287,7 @@ FD_form_spellchecker * FormPreferences::build_spellchecker()
FD_form_inputs_misc::~FD_form_inputs_misc()
{
if (form->visible ) fl_hide_form( form );
if ( form->visible ) fl_hide_form( form );
fl_free_form( form );
}
@ -314,7 +314,7 @@ FD_form_inputs_misc * FormPreferences::build_inputs_misc()
FD_form_language::~FD_form_language()
{
if (form->visible ) fl_hide_form( form );
if ( form->visible ) fl_hide_form( form );
fl_free_form( form );
}
@ -386,7 +386,7 @@ FD_form_language * FormPreferences::build_language()
FD_form_colours::~FD_form_colours()
{
if (form->visible ) fl_hide_form( form );
if ( form->visible ) fl_hide_form( form );
fl_free_form( form );
}
@ -449,7 +449,7 @@ FD_form_colours * FormPreferences::build_colours()
FD_form_converters::~FD_form_converters()
{
if (form->visible ) fl_hide_form( form );
if ( form->visible ) fl_hide_form( form );
fl_free_form( form );
}
@ -497,7 +497,7 @@ FD_form_converters * FormPreferences::build_converters()
FD_form_formats::~FD_form_formats()
{
if (form->visible ) fl_hide_form( form );
if ( form->visible ) fl_hide_form( form );
fl_free_form( form );
}
@ -549,7 +549,7 @@ FD_form_formats * FormPreferences::build_formats()
FD_form_lnf_misc::~FD_form_lnf_misc()
{
if (form->visible ) fl_hide_form( form );
if ( form->visible ) fl_hide_form( form );
fl_free_form( form );
}
@ -617,7 +617,7 @@ FD_form_lnf_misc * FormPreferences::build_lnf_misc()
FD_form_interface::~FD_form_interface()
{
if (form->visible ) fl_hide_form( form );
if ( form->visible ) fl_hide_form( form );
fl_free_form( form );
}
@ -666,7 +666,7 @@ FD_form_interface * FormPreferences::build_interface()
FD_form_printer::~FD_form_printer()
{
if (form->visible ) fl_hide_form( form );
if ( form->visible ) fl_hide_form( form );
fl_free_form( form );
}
@ -745,7 +745,7 @@ FD_form_printer * FormPreferences::build_printer()
FD_form_paths::~FD_form_paths()
{
if (form->visible ) fl_hide_form( form );
if ( form->visible ) fl_hide_form( form );
fl_free_form( form );
}

View File

@ -12,7 +12,7 @@
FD_form_print::~FD_form_print()
{
if (form->visible ) fl_hide_form( form );
if ( form->visible ) fl_hide_form( form );
fl_free_form( form );
}

View File

@ -12,7 +12,7 @@
FD_form_ref::~FD_form_ref()
{
if (form->visible ) fl_hide_form( form );
if ( form->visible ) fl_hide_form( form );
fl_free_form( form );
}

View File

@ -12,7 +12,7 @@
FD_form_tabular::~FD_form_tabular()
{
if (form->visible ) fl_hide_form( form );
if ( form->visible ) fl_hide_form( form );
fl_free_form( form );
}
@ -51,7 +51,7 @@ FD_form_tabular * FormTabular::build_tabular()
FD_form_tabular_options::~FD_form_tabular_options()
{
if (form->visible ) fl_hide_form( form );
if ( form->visible ) fl_hide_form( form );
fl_free_form( form );
}
@ -106,7 +106,7 @@ FD_form_tabular_options * FormTabular::build_tabular_options()
FD_form_column_options::~FD_form_column_options()
{
if (form->visible ) fl_hide_form( form );
if ( form->visible ) fl_hide_form( form );
fl_free_form( form );
}
@ -196,7 +196,7 @@ FD_form_column_options * FormTabular::build_column_options()
FD_form_cell_options::~FD_form_cell_options()
{
if (form->visible ) fl_hide_form( form );
if ( form->visible ) fl_hide_form( form );
fl_free_form( form );
}
@ -293,7 +293,7 @@ FD_form_cell_options * FormTabular::build_cell_options()
FD_form_longtable_options::~FD_form_longtable_options()
{
if (form->visible ) fl_hide_form( form );
if ( form->visible ) fl_hide_form( form );
fl_free_form( form );
}

View File

@ -12,7 +12,7 @@
FD_form_tabular_create::~FD_form_tabular_create()
{
if (form->visible ) fl_hide_form( form );
if ( form->visible ) fl_hide_form( form );
fl_free_form( form );
}

View File

@ -12,7 +12,7 @@
FD_form_toc::~FD_form_toc()
{
if (form->visible ) fl_hide_form( form );
if ( form->visible ) fl_hide_form( form );
fl_free_form( form );
}

View File

@ -12,7 +12,7 @@
FD_form_url::~FD_form_url()
{
if (form->visible ) fl_hide_form( form );
if ( form->visible ) fl_hide_form( form );
fl_free_form( form );
}

View File

@ -8,7 +8,7 @@ s/\(.*\) \*create_form_form[^ ]*/\1::~\1()/p
/\(.*\)::~\(.*\)()/{
i\
{\
if( form->visible ) fl_hide_form( form );\
if ( form->visible ) fl_hide_form( form );\
fl_free_form( form );\
}\
\