# HG changeset patch # User Mario de Sousa # Date 1334760240 -3600 # Node ID 773303b7f31f52159a3374fec3fdc80a7dd6e9e6 # Parent f9cff11ae6229c94231b72364cb35584a1b58c87 Remove potential access to NULL pointer. diff -r f9cff11ae622 -r 773303b7f31f stage3/fill_candidate_datatypes.cc --- a/stage3/fill_candidate_datatypes.cc Wed Apr 18 13:29:08 2012 +0100 +++ b/stage3/fill_candidate_datatypes.cc Wed Apr 18 15:44:00 2012 +0100 @@ -689,8 +689,10 @@ void *fill_candidate_datatypes_c::visit(located_var_decl_c *symbol) { symbol->located_var_spec_init->accept(*this); symbol->location->accept(*this); - symbol->variable_name->candidate_datatypes = symbol->location->candidate_datatypes; - intersect_candidate_datatype_list(symbol->variable_name /*origin, dest.*/, symbol->located_var_spec_init /*with*/); + if (NULL != symbol->variable_name) { + symbol->variable_name->candidate_datatypes = symbol->location->candidate_datatypes; + intersect_candidate_datatype_list(symbol->variable_name /*origin, dest.*/, symbol->located_var_spec_init /*with*/); + } return NULL; }