summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVinson Lee <vlee@freedesktop.org>2021-01-04 20:27:42 -0800
committerVinson Lee <vlee@freedesktop.org>2021-01-08 18:28:43 -0800
commit5c59e4efe2d5c16cef47ee452c2a189b19a68d19 (patch)
tree8dd3cbe57de212efee59d5a669e4f80b38af2386
parentfb4e67df1e7a2a1ddb6928aae6fd2188aa0c5bf1 (diff)
clover: Add constructor for clover::module.
Fix defect reported by Coverity Scan after commit 95527fe2292 ("clover/module: add a printf support to module (v5)"). Uninitialized scalar variable (UNINIT) uninit_use_in_call: Using uninitialized value m.printf_strings_in_buffer when calling module. Signed-off-by: Vinson Lee <vlee@freedesktop.org> Reviewed-by: Francisco Jerez <currojerez@riseup.net> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8322>
-rw-r--r--src/gallium/frontends/clover/core/module.hpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/gallium/frontends/clover/core/module.hpp b/src/gallium/frontends/clover/core/module.hpp
index 1d1f803520f..b014d3c40cb 100644
--- a/src/gallium/frontends/clover/core/module.hpp
+++ b/src/gallium/frontends/clover/core/module.hpp
@@ -153,6 +153,7 @@ namespace clover {
std::vector<argument> args;
};
+ module() : printf_strings_in_buffer(0) { }
void serialize(std::ostream &os) const;
static module deserialize(std::istream &is);
size_t size() const;