summaryrefslogtreecommitdiffstats
path: root/source
diff options
context:
space:
mode:
authorTim Foley <tfoleyNV@users.noreply.github.com>2020-09-03 23:00:53 -0700
committerGitHub <noreply@github.com>2020-09-03 23:00:53 -0700
commit5e10f1b4f0654515af1fcb29e8d1f35e691c8aa3 (patch)
tree705efacd53e5a8abcf683d7e0c3e951b16f4ba63 /source
parent5534b0d2b98b9d811028abdfe43f708226f5768f (diff)
Fix a crashing issue for non-end-to-end compilation (#1532)
The refactorings that added support for multiple entry points in an output file seemingly introduced a regression such that we crash on compilation that is not "end-to-end." Unfortunately, all of our testing only covers end-to-end compilation, and many users only use that mode. I've added a fix for the issue I ran into, but I haven't addressed the testing gap in this change. Without adding testing for non-end-to-end compilation, I expect further regressions to slip in over time. Co-authored-by: Yong He <yonghe@outlook.com>
Diffstat (limited to 'source')
-rwxr-xr-xsource/slang/slang-compiler.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/source/slang/slang-compiler.cpp b/source/slang/slang-compiler.cpp
index 9b567a7d7..859da5d11 100755
--- a/source/slang/slang-compiler.cpp
+++ b/source/slang/slang-compiler.cpp
@@ -1226,7 +1226,7 @@ SlangResult dissassembleDXILUsingDXC(
CodeGenTarget sourceTarget = CodeGenTarget::None;
SourceLanguage sourceLanguage = SourceLanguage::Unknown;
- PassThroughMode downstreamCompiler = endToEndReq->passThrough;
+ PassThroughMode downstreamCompiler = endToEndReq ? endToEndReq->passThrough : PassThroughMode::None;
// If we are not in pass through, lookup the default compiler for the emitted source type
if (downstreamCompiler == PassThroughMode::None)