Fix asan/tsan env options handling (#55753)

Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/55753

The warning "ASAN and TSAN modes cannot be used together" was incorrectly displayed when only ASAN was enabled. This happened because the condition checked only `enableASAN` instead of `enableASAN && enableTSAN`. Updated the conditional logic to properly check that both flags are enabled before showing the conflict warning.

Changelog: [Internal]

Reviewed By: NickGerleman

Differential Revision: D94393117

fbshipit-source-id: f7a96de11230710e8d54c17d4c89edb569ebaa07
This commit is contained in:
Nick Lefever
2026-02-25 13:19:50 -08:00
committed by meta-codesync[bot]
parent 984dbe83d8
commit 017bf1a7f0
+1 -1
View File
@@ -70,7 +70,7 @@ export function getBuckModesForPlatform(
});
}
} else {
if (EnvironmentOptions.enableASAN) {
if (EnvironmentOptions.enableASAN && EnvironmentOptions.enableTSAN) {
printConsoleLog({
type: 'console-log',
level: 'warn',