forked from 0ad/0ad
Early return in PreprocessorWrapper in case of failed include resolve.
This was SVN commit r24951.
This commit is contained in:
parent
2ce0c2b988
commit
32c3f4fb90
@ -237,7 +237,8 @@ CStr CPreprocessorWrapper::ResolveIncludes(const CStr& source)
|
|||||||
// After resolving the following vector should contain a complete list
|
// After resolving the following vector should contain a complete list
|
||||||
// to concatenate.
|
// to concatenate.
|
||||||
std::vector<std::string_view> processedParts;
|
std::vector<std::string_view> processedParts;
|
||||||
ResolveIncludesImpl(source, m_IncludeCache, m_IncludeCallback, chunks, processedParts);
|
if (!ResolveIncludesImpl(source, m_IncludeCache, m_IncludeCallback, chunks, processedParts))
|
||||||
|
return {};
|
||||||
std::size_t totalSize = 0;
|
std::size_t totalSize = 0;
|
||||||
for (const std::string_view& part : processedParts)
|
for (const std::string_view& part : processedParts)
|
||||||
totalSize += part.size();
|
totalSize += part.size();
|
||||||
|
Loading…
Reference in New Issue
Block a user