
**Describe the bug**
[A link to the report](https://s3.amazonaws.com/clickhouse-test-reports/32291/2f43445a34c91beb1104422308ba5abfdf7be5bb/fuzzer_astfuzzertsan,actions//report.html)

**How to reproduce**

```SQL
CREATE TABLE t1 (`id` Int32, `key` String, `key2` String) ENGINE = TinyLog;
CREATE TABLE t2 (`id` Int32, `key` String, `key2` String) ENGINE = TinyLog;
SELECT (t1.id = t2.id) AND (t2.key = t2.key2) AND ((t1.id = t2.id) AND (t2.key = t2.key2) AND (t1.key = t1.key2) AND (t2.key2 = NULL)) AND (t1.key = t1.key2) AND (t2.key2 = NULL), NULL FROM t1 ANY INNER JOIN t2 ON (t1.key = t1
.key2) AND (NULL = t1.key) AND (t2.key = t2.key2) AND ((NULL = t1.key) = t2.id) AND (('' = t1.key) = t2.id) AND (t2.key2 = NULL);
```

{
    for (size_t i = 0; i < block.columns(); ++i)
    {
        auto & column = block.getByPosition(i);
        if (!column.column) 
            column.column = column.type->createColumn();
    }
}
void joinTotals(Block left_totals, Block right_totals, const TableJoin & table_join, Block & out_block)
{
    if (table_join.forceNullableLeft())
        JoinCommon::convertColumnsToNullable(left_totals);
    if (table_join.forceNullableRight())
        JoinCommon::convertColumnsToNullable(right_totals);
    for (auto & col : out_block)
    {
        if (const auto * left_col = left_totals.findByName(col.name))
            col = *left_col;
        else if (const auto * right_col = right_totals.findByName(col.name))
            col = *right_col;
        else
            col.column = col.type->createColumnConstWithDefaultValue(1)->convertToFullColumnIfConst();
        
        if (col.column->size() != 1)
            col.column = col.column->cloneResized(1);
    }
}
void addDefaultValues(IColumn & column, const DataTypePtr & type, size_t count)