st/nine: pass NULL to ureg_get_tokens()
authorTimothy Arceri <tarceri@itsqueeze.com>
Thu, 2 Mar 2017 23:12:09 +0000 (10:12 +1100)
committerTimothy Arceri <tarceri@itsqueeze.com>
Wed, 8 Mar 2017 22:29:07 +0000 (09:29 +1100)
The number of tokens in never used and the pointer is NULL checked
so just pass NULL.

Reviewed-by: Axel Davy <axel.davy@ens.fr>
src/gallium/state_trackers/nine/nine_ff.c
src/gallium/state_trackers/nine/nine_shader.c

index 279ba374896b61bc7820c9f7c9c1c85771385b44..2175bdbcc51d9cf645a9e9dafe21fe1e4e1cbaeb 100644 (file)
@@ -171,8 +171,7 @@ static void nine_ff_prune_ps(struct NineDevice9 *);
 static void nine_ureg_tgsi_dump(struct ureg_program *ureg, boolean override)
 {
     if (debug_get_bool_option("NINE_FF_DUMP", FALSE) || override) {
-        unsigned count;
-        const struct tgsi_token *toks = ureg_get_tokens(ureg, &count);
+        const struct tgsi_token *toks = ureg_get_tokens(ureg, NULL);
         tgsi_dump(toks, 0);
         ureg_free_tokens(toks);
     }
index 95bc6ec90353bab08f1d47360a570faa6610943c..7760a1ce1d3eda1efcce208c4a80fefb1fb9c3cf 100644 (file)
@@ -3705,8 +3705,7 @@ nine_translate_shader(struct NineDevice9 *device, struct nine_shader_info *info,
         ureg_DECL_constant2D(tx->ureg, 0, 2, 4); /* Viewport data */
 
     if (debug_get_bool_option("NINE_TGSI_DUMP", FALSE)) {
-        unsigned count;
-        const struct tgsi_token *toks = ureg_get_tokens(tx->ureg, &count);
+        const struct tgsi_token *toks = ureg_get_tokens(tx->ureg, NULL);
         tgsi_dump(toks, 0);
         ureg_free_tokens(toks);
     }