aboutsummaryrefslogtreecommitdiffstats
path: root/src/gallium/auxiliary/gallivm
diff options
context:
space:
mode:
authorJan Zielinski <[email protected]>2020-02-05 13:57:55 +0100
committerMarge Bot <[email protected]>2020-02-05 16:08:44 +0000
commit23c137612bea1e319ecdfb894c020b6651f4909a (patch)
tree0a93a78e36dd118667bfcb7d550b4807684d6a77 /src/gallium/auxiliary/gallivm
parent7eaf21cb6f67adbe0e79b80b4feb8c816a98a720 (diff)
gallium/swr: Fix various asserts and security issues
To improve the robustness of the code, we want to better detect issues in testing (using asserts) and use more secure techniques. Reviewed-by: Krzysztof Raszkowski <[email protected]> Tested-by: Marge Bot <https://gitlab.freedesktop.org/mesa/mesa/merge_requests/3710> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/merge_requests/3710>
Diffstat (limited to 'src/gallium/auxiliary/gallivm')
-rw-r--r--src/gallium/auxiliary/gallivm/lp_bld_init.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/gallium/auxiliary/gallivm/lp_bld_init.c b/src/gallium/auxiliary/gallivm/lp_bld_init.c
index efc0096a744..6206d79cc54 100644
--- a/src/gallium/auxiliary/gallivm/lp_bld_init.c
+++ b/src/gallium/auxiliary/gallivm/lp_bld_init.c
@@ -450,7 +450,7 @@ lp_build_init(void)
*/
lp_native_vector_width = 128;
}
-
+
lp_native_vector_width = debug_get_num_option("LP_NATIVE_VECTOR_WIDTH",
lp_native_vector_width);
@@ -513,6 +513,7 @@ gallivm_create(const char *name, LLVMContextRef context)
}
}
+ assert(gallivm != NULL);
return gallivm;
}