translate_sse: Silence uninitialized variable warnings.
authorVinson Lee <vlee@vmware.com>
Sun, 22 Aug 2010 06:24:28 +0000 (23:24 -0700)
committerVinson Lee <vlee@vmware.com>
Sun, 22 Aug 2010 06:24:28 +0000 (23:24 -0700)
Initialize variables on error paths.

src/gallium/auxiliary/translate/translate_sse.c

index 06b8f32fe6b908bcdcdb424352af70c8425dd372..5188e49cd506dcc2bc683f17e132dcc3bb4b8190 100644 (file)
@@ -553,6 +553,13 @@ static boolean translate_attr_convert( struct translate_sse *p,
                case 32:
                   factor = get_inv_2147483647(p);
                   break;
+               default:
+                  assert(0);
+                  factor.disp = 0;
+                  factor.file = 0;
+                  factor.idx = 0;
+                  factor.mod = 0;
+                  break;
                }
                sse_mulps(p->func, dataXMM, factor);
             }
@@ -596,6 +603,13 @@ static boolean translate_attr_convert( struct translate_sse *p,
                case 32:
                   factor = get_inv_2147483647(p);
                   break;
+               default:
+                  assert(0);
+                  factor.disp = 0;
+                  factor.file = 0;
+                  factor.idx = 0;
+                  factor.mod = 0;
+                  break;
                }
                sse_mulps(p->func, dataXMM, factor);
             }