From ce39714228cc0d233206379290c9d2f0b30ad21e Mon Sep 17 00:00:00 2001 From: Henri Verbeet Date: Tue, 27 Jul 2010 12:54:49 +0200 Subject: [PATCH] wined3d: Check for unread registers in a more logical way in handle_ps3_input(). ~0U always >= (in_count + 2). --- dlls/wined3d/glsl_shader.c | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/dlls/wined3d/glsl_shader.c b/dlls/wined3d/glsl_shader.c index 89bc6acee9f..77360657ba4 100644 --- a/dlls/wined3d/glsl_shader.c +++ b/dlls/wined3d/glsl_shader.c @@ -3757,13 +3757,11 @@ static void handle_ps3_input(struct wined3d_shader_buffer *buffer, const struct if (!(input_map & 1)) continue; in_idx = map[i]; - if (in_idx >= (in_count + 2)) { - FIXME("More input varyings declared than supported, expect issues\n"); - continue; - } - else if (map[i] == ~0U) + /* Declared, but not read register */ + if (in_idx == ~0U) continue; + if (in_idx >= (in_count + 2)) { - /* Declared, but not read register */ + FIXME("More input varyings declared than supported, expect issues.\n"); continue; } -- 2.11.4.GIT