Problem: Coverity warns for using NULL pointer.
Solution: Check that lhs_type is not NULL.
static int included_patches[] =
{ /* Add new patch number below this line */
+/**/
+ 1340,
/**/
1339,
/**/
lhs->lhs_type = &t_any;
}
- int use_class = lhs->lhs_type->tt_type == VAR_CLASS
- || lhs->lhs_type->tt_type == VAR_OBJECT;
+ int use_class = lhs->lhs_type != NULL
+ && (lhs->lhs_type->tt_type == VAR_CLASS
+ || lhs->lhs_type->tt_type == VAR_OBJECT);
if (lhs->lhs_type == NULL
|| (use_class ? lhs->lhs_type->tt_class == NULL
: lhs->lhs_type->tt_member == NULL))