[Mesa-dev] [PATCH 1/4] winsys/svga: remove useless assertion

Brian Paul brianp at vmware.com
Thu Sep 10 08:03:59 PDT 2015


An unsigned int is always >= 0.  Found with Coverity.
---
 src/gallium/winsys/svga/drm/vmw_context.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/src/gallium/winsys/svga/drm/vmw_context.c b/src/gallium/winsys/svga/drm/vmw_context.c
index 394795e..1675af4 100644
--- a/src/gallium/winsys/svga/drm/vmw_context.c
+++ b/src/gallium/winsys/svga/drm/vmw_context.c
@@ -591,7 +591,6 @@ vmw_swc_commit(struct svga_winsys_context *swc)
 {
    struct vmw_svga_winsys_context *vswc = vmw_svga_winsys_context(swc);
 
-   assert(vswc->command.reserved >= 0);
    assert(vswc->command.used + vswc->command.reserved <= vswc->command.size);
    vswc->command.used += vswc->command.reserved;
    vswc->command.reserved = 0;
-- 
1.9.1



More information about the mesa-dev mailing list