mirror of
https://github.com/projectM-visualizer/projectm.git
synced 2026-08-18 11:05:35 +00:00
Fix HLSLParser: Always check preprocessor directive stack to be empty before using the top element
This commit is contained in:
2
vendor/hlslparser/src/HLSLParser.cpp
vendored
2
vendor/hlslparser/src/HLSLParser.cpp
vendored
@ -3614,7 +3614,7 @@ bool HLSLParser::ApplyPreprocessor(const char* fileName, const char* buffer, siz
|
||||
isCodeActive.push(true);
|
||||
m_tokenizer = HLSLTokenizer(fileName, buffer, length);
|
||||
sourcePreprocessed.clear();
|
||||
while (m_tokenizer.GetToken() != HLSLToken_EndOfStream)
|
||||
while (m_tokenizer.GetToken() != HLSLToken_EndOfStream && !isCodeActive.empty())
|
||||
{
|
||||
bool addOriginalSource = true;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user