Module: wine Branch: master Commit: bfb7e167cb399dbba0a889b797bc11ece8b9e687 URL: http://source.winehq.org/git/wine.git/?a=commit;h=bfb7e167cb399dbba0a889b797...
Author: Pierre Schweitzer pierre@reactos.org Date: Sun May 1 17:50:18 2016 +0200
user32: Check bounds before dereferencing.
Signed-off-by: Pierre Schweitzer pierre@reactos.org Signed-off-by: Alexandre Julliard julliard@winehq.org
---
dlls/user32/edit.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/dlls/user32/edit.c b/dlls/user32/edit.c index ca40ed0..179d44a 100644 --- a/dlls/user32/edit.c +++ b/dlls/user32/edit.c @@ -305,7 +305,7 @@ static INT EDIT_WordBreakProc(EDITSTATE *es, LPWSTR s, INT index, INT count, INT case WB_RIGHT: if (!count) break; - while (s[index] && index < count && !es->logAttr[index].fSoftBreak) + while (index < count && s[index] && !es->logAttr[index].fSoftBreak) index++; ret = index; break;