mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-06-13 05:08:20 +02:00
r300g: Check for bogus texture targets.
This commit is contained in:
parent
b62d339301
commit
945cea01d9
1 changed files with 6 additions and 0 deletions
|
|
@ -192,6 +192,12 @@ static boolean r300_is_format_supported(struct pipe_screen* screen,
|
|||
uint32_t retval = 0;
|
||||
boolean is_r500 = r300_screen(screen)->caps->is_r500;
|
||||
|
||||
if (target >= PIPE_MAX_TEXTURE_TYPES) {
|
||||
debug_printf("r300: Implementation error: Received bogus texture "
|
||||
"target %d in %s\n", target, __FUNCTION__);
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
switch (format) {
|
||||
/* Supported formats. */
|
||||
/* Colorbuffer */
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue