Ken Thomases : winemac: Fix an off-by-one error in macdrv_wglChoosePixelFormatARB().

Alexandre Julliard julliard at winehq.org
Thu Apr 25 14:25:18 CDT 2013


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

Author: Ken Thomases <ken at codeweavers.com>
Date:   Wed Apr 24 20:18:43 2013 -0500

winemac: Fix an off-by-one error in macdrv_wglChoosePixelFormatARB().

---

 dlls/winemac.drv/opengl.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/dlls/winemac.drv/opengl.c b/dlls/winemac.drv/opengl.c
index e72281a..5f269fc 100644
--- a/dlls/winemac.drv/opengl.c
+++ b/dlls/winemac.drv/opengl.c
@@ -1917,8 +1917,8 @@ static BOOL macdrv_wglChoosePixelFormatARB(HDC hdc, const int *piAttribIList,
         else if (accum_bits || accum_red_bits || accum_green_bits || accum_blue_bits || accum_alpha_bits)
             continue;
 
-        piFormats[found++] = i;
-        TRACE("match: pixel format %d %s\n", i, debugstr_pf(&pixel_formats[i]));
+        piFormats[found++] = i + 1;
+        TRACE("match: pixel format %d %s\n", i + 1, debugstr_pf(&pixel_formats[i]));
     }
 
 cant_match:




More information about the wine-cvs mailing list