Kirill K. Smirnov : winhlp32: Fix off-by-one error.

Alexandre Julliard julliard at winehq.org
Tue Aug 5 07:26:46 CDT 2008


Module: wine
Branch: master
Commit: 52081393bc897b56e2932b5718c9ef49570e8c15
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=52081393bc897b56e2932b5718c9ef49570e8c15

Author: Kirill K. Smirnov <lich at math.spbu.ru>
Date:   Mon Aug  4 03:49:20 2008 +0400

winhlp32: Fix off-by-one error.

---

 programs/winhlp32/hlpfile.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/programs/winhlp32/hlpfile.c b/programs/winhlp32/hlpfile.c
index 870bac7..7f1a931 100644
--- a/programs/winhlp32/hlpfile.c
+++ b/programs/winhlp32/hlpfile.c
@@ -1639,7 +1639,7 @@ BOOL    HLPFILE_BrowsePage(HLPFILE_PAGE* page, struct RtfData* rd,
         case 0x20:
         case 0x23:
             if (!HLPFILE_BrowseParagraph(page, rd, buf, end, &parlen)) return FALSE;
-            if (relative >= index * 0x8000 + offs)
+            if (relative > index * 0x8000 + offs)
                 rd->char_pos_rel = rd->char_pos;
             offs += parlen;
             break;




More information about the wine-cvs mailing list