Commit 5da02fd222a98a57366a5fb4e43028a51f0112e3
1 parent
d647a41c
Fix heap-buffer-overflow
Change-Id: I4d9f4edcc0715850aa60c06c31d5f95744014297
Showing
1 changed file
with
2 additions
and
0 deletions
examples/refraction-effect/refraction-effect-example.cpp
| @@ -480,6 +480,8 @@ private: | @@ -480,6 +480,8 @@ private: | ||
| 480 | return; | 480 | return; |
| 481 | } | 481 | } |
| 482 | 482 | ||
| 483 | + fileBuffer.PushBack( '\0' ); | ||
| 484 | + | ||
| 483 | std::stringstream iss( &fileBuffer[0], std::ios::in ); | 485 | std::stringstream iss( &fileBuffer[0], std::ios::in ); |
| 484 | 486 | ||
| 485 | boundingBox.Resize( 6 ); | 487 | boundingBox.Resize( 6 ); |