diff options
author | rubidium <rubidium@openttd.org> | 2014-01-13 17:54:24 +0000 |
---|---|---|
committer | rubidium <rubidium@openttd.org> | 2014-01-13 17:54:24 +0000 |
commit | a942619911b89c7b761d98c826d0e943e6f8b22e (patch) | |
tree | 53d56dc94fbdd3f174521dc69d94fcf1865596a5 /src/video | |
parent | 54a898be33588161249cc7b57637aed6ae2237cc (diff) | |
download | openttd-a942619911b89c7b761d98c826d0e943e6f8b22e.tar.xz |
(svn r26247) -Fix [FS#5854, FS#5855]: Possible out of bounds reads with the sse blitters (MJP)
Diffstat (limited to 'src/video')
-rw-r--r-- | src/video/win32_v.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/video/win32_v.cpp b/src/video/win32_v.cpp index 02cae68e2..186ac1025 100644 --- a/src/video/win32_v.cpp +++ b/src/video/win32_v.cpp @@ -1077,7 +1077,7 @@ static bool AllocateDibSection(int w, int h, bool force) bi->bmiHeader.biSize = sizeof(BITMAPINFOHEADER); bi->bmiHeader.biWidth = _wnd.width = w; - bi->bmiHeader.biHeight = -(_wnd.height = h+1); // Allocate extra room to prevent out-of-bounds when SSE reads a 16B block at the end of the buffer. + bi->bmiHeader.biHeight = -(_wnd.height = h); bi->bmiHeader.biPlanes = 1; bi->bmiHeader.biBitCount = BlitterFactory::GetCurrentBlitter()->GetScreenDepth(); |