diff options
author | Christoph Bumiller <[email protected]> | 2013-01-19 20:53:22 +0100 |
---|---|---|
committer | Christoph Bumiller <[email protected]> | 2013-01-19 20:54:39 +0100 |
commit | 7d2d450ea6d8082db14cd3f86c6c25442bf771c5 (patch) | |
tree | 7f2c02f9374a854eceae47b59b4de80a4106d987 /src/gallium/drivers/nv30/nv30_screen.c | |
parent | b0863c26d43a9ed135c8db980fb0bc9bca35548c (diff) |
nouveau: fix undefined behaviour when testing sample_count
NOTE: This is a candidate for the 9.0 branch.
Diffstat (limited to 'src/gallium/drivers/nv30/nv30_screen.c')
-rw-r--r-- | src/gallium/drivers/nv30/nv30_screen.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/gallium/drivers/nv30/nv30_screen.c b/src/gallium/drivers/nv30/nv30_screen.c index 06f7c42bbe5..f3faf8ad18a 100644 --- a/src/gallium/drivers/nv30/nv30_screen.c +++ b/src/gallium/drivers/nv30/nv30_screen.c @@ -244,6 +244,8 @@ nv30_screen_is_format_supported(struct pipe_screen *pscreen, unsigned sample_count, unsigned bindings) { + if (sample_count > 4) + return FALSE; if (!(0x00000017 & (1 << sample_count))) return FALSE; |