From bug-octave-request at bevo dot che dot wisc dot edu Tue Apr 7 15:45:03 1998 Subject: bus error while senseless making global ... From: "John W. Eaton" To: Guido Dietz Cc: bug-octave at bevo dot che dot wisc dot edu Date: Tue, 7 Apr 1998 15:41:13 -0500 (CDT) On 7-Apr-1998, Guido Dietz wrote: | Bug report for Octave 2.0.11 configured for hppa1.1-hp-hpux10.20 | | Description: | ----------- | Trying to make a builtin constant global results in: | | 1>> global i | error: bus error -- stopping myself... | attempting to save variables to `octave-core'... | save to `octave-core' complete Please try the following patch. Thanks! jwe Tue Apr 7 15:38:29 1998 John W. Eaton * symtab.cc (symbol_record::variable_value): Avoid dereferencing NULL pointer. *** symtab.cc.orig Tue Apr 7 15:40:01 1998 --- symtab.cc Tue Apr 7 15:40:17 1998 *************** *** 617,623 **** if (is_variable ()) { tree_constant *tmp = (tree_constant *) def (); ! retval = tmp->value (); } return retval; --- 617,625 ---- if (is_variable ()) { tree_constant *tmp = (tree_constant *) def (); ! ! if (tmp) ! retval = tmp->value (); } return retval;