8
0
mirror of https://github.com/FirebirdSQL/firebird.git synced 2025-01-23 02:03:04 +01:00

One more correction. This restores the accidentally changed original logic.

This commit is contained in:
dimitr 2012-05-17 09:10:13 +00:00
parent f8b30d6895
commit 4b35572f29

View File

@ -1390,11 +1390,13 @@ static jrd_nod* par_field(thread_db* tdbb, CompilerScratch* csb, SSHORT blr_oper
{
fb_assert(id >= 0);
if (temp_rel->rel_fields && id < (int) temp_rel->rel_fields->count())
{
const jrd_fld* const field = (*temp_rel->rel_fields)[id];
jrd_fld* field;
if (field && field->fld_default_value && field->fld_not_null)
if (temp_rel->rel_fields &&
id < (int) temp_rel->rel_fields->count() &&
(field = (*temp_rel->rel_fields)[id]))
{
if (field->fld_default_value && field->fld_not_null)
node->nod_arg[e_fld_default_value] = field->fld_default_value;
}
else if (temp_rel->rel_flags & REL_system)