Fixes a preprocessor bug.
The preprocessor could look beyond the end of a buffer. The issue was discovered by vultraz, who also tested the patch.
This commit is contained in:
parent
dcff6a6475
commit
8a2ddc368f
2 changed files with 4 additions and 0 deletions
|
@ -219,6 +219,7 @@ Version 1.11.0-svn:
|
|||
* Changed: Rewrote the surface blending algorithm, and improving its speed
|
||||
using NEON intrinsics on processors supporting NEON (the Pandora).
|
||||
* Fixed bug #19503: "maximum auto saves" setting now works correctly.
|
||||
* Fixed: A preprocessor bug looking beyond the end of a buffer.
|
||||
|
||||
Version 1.10.0:
|
||||
* Campaigns:
|
||||
|
|
|
@ -311,6 +311,9 @@ int preprocessor_streambuf::underflow()
|
|||
}
|
||||
// Update the internal state and data pointers
|
||||
out_buffer_ = buffer_.str();
|
||||
if(out_buffer_.empty()) {
|
||||
return EOF;
|
||||
}
|
||||
char *begin = &*out_buffer_.begin();
|
||||
unsigned bs = out_buffer_.size();
|
||||
setg(begin, begin + sz, begin + bs);
|
||||
|
|
Loading…
Add table
Reference in a new issue