(you don't have to strictly follow this form)

**Describe the bug**
A link to the report: https://s3.amazonaws.com/clickhouse-test-reports/35466/d81c58b5d9be45ac69c3859b5cbe97080711f6d9/fuzzer_astfuzzerubsan,actions//report.html
The commit: https://github.com/ClickHouse/ClickHouse/commit/d81c58b5d9be45ac69c3859b5cbe97080711f6d9
if (query.limit_with_ties && apply_offset)
            {
                executeLimit(query_plan);
            }
            
            
            if (!to_aggregation_stage)
            {
                
                executeProjection(query_plan, expressions.final_projection);
            }
            
            executeExtremes(query_plan);
            bool limit_applied = apply_prelimit || (query.limit_with_ties && apply_offset);
            
            
            
            
            
            
            if (apply_limit && !limit_applied && apply_offset)
                executeLimit(query_plan);
            if (apply_offset)
                executeOffset(query_plan);
        }
    }
    if (!subqueries_for_sets.empty() && (expressions.hasHaving() || query_analyzer->hasGlobalSubqueries()))
        executeSubqueriesInSetsAndJoins(query_plan, subqueries_for_sets);
}
static StreamLocalLimits getLimitsForStorage(const Settings & settings, const SelectQueryOptions & options)