mesa: fix error codes for importing memory/semaphore FDs

This fixes the following piglit tests:
spec/ext_semaphore_fd/api-errors/import-semaphore-fd-bad-enum
spec/ext_memory_object_fd/api-errors/import-memory-fd-bad-enum

Signed-off-by: Andres Rodriguez <andresx7@gmail.com>
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
This commit is contained in:
Andres Rodriguez 2017-12-21 17:59:07 -05:00
parent 50b06cbc10
commit 0ebd3cc863

View file

@ -809,7 +809,7 @@ _mesa_ImportMemoryFdEXT(GLuint memory,
}
if (handleType != GL_HANDLE_TYPE_OPAQUE_FD_EXT) {
_mesa_error(ctx, GL_INVALID_VALUE, "%s(handleType=%u)", func, handleType);
_mesa_error(ctx, GL_INVALID_ENUM, "%s(handleType=%u)", func, handleType);
return;
}
@ -836,7 +836,7 @@ _mesa_ImportSemaphoreFdEXT(GLuint semaphore,
}
if (handleType != GL_HANDLE_TYPE_OPAQUE_FD_EXT) {
_mesa_error(ctx, GL_INVALID_VALUE, "%s(handleType=%u)", func, handleType);
_mesa_error(ctx, GL_INVALID_ENUM, "%s(handleType=%u)", func, handleType);
return;
}