diff options
| author | 2025-11-15 19:31:12 +0000 | |
|---|---|---|
| committer | 2025-11-15 19:31:12 +0000 | |
| commit | 650bb761d3e5af3f8fa19ac8d22864cc0360d085 (patch) | |
| tree | e831873f4dfa77d02815d7ab2f6a73169a1c262f | |
| parent | 74f1309af5310fbfa346048f8ecfc7fe1e8a4571 (diff) | |
| download | sst-650bb761d3e5af3f8fa19ac8d22864cc0360d085.tar.gz sst-650bb761d3e5af3f8fa19ac8d22864cc0360d085.zip | |
Fix incorrect gamedata short-circuiting
Gamedata bugs are the gift that keeps on giving. This was making vgui
stuff fail in L4D2 because the other outer conditions would match first.
It's perhaps unfortunate that we have to remove short-circuiting in
cases where it would work fine, but who knows, maybe the compiler would
be smart enough to figure it out anyway.
At any rate it's necessary for correctness, so whatever.
| -rw-r--r-- | src/build/mkgamedata.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/build/mkgamedata.c b/src/build/mkgamedata.c index 2ae9228..e0d08f3 100644 --- a/src/build/mkgamedata.c +++ b/src/build/mkgamedata.c @@ -260,7 +260,7 @@ Fi(" if (%sGAMETYPE_MATCHES(%s)) {", excl, sbase + tags[i] + neg); else { _i("}") F( "#line %d \"%" fS "\"", srclines[i], srcnames[srcfiles[i]]) -Fi("else if (%sGAMETYPE_MATCHES(%s)) {", excl, sbase + tags[i] + neg); +Fi("if (%sGAMETYPE_MATCHES(%s)) {", excl, sbase + tags[i] + neg); } if (exprs[i]) { F( "#line %d \"%" fS "\"", srclines[i], srcnames[srcfiles[i]]) |
