From: Vinson Lee Date: Sat, 4 Aug 2012 21:37:33 +0000 (-0700) Subject: gallivm: Add constructor for raw_debug_ostream. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=c3894bc2d5d5eabdc913d88d1fedc552fef074a5;p=mesa.git gallivm: Add constructor for raw_debug_ostream. Fixes uninitialized scalar field defect reported by Coverity. Signed-off-by: Vinson Lee Reviewed-by: José Fonseca --- diff --git a/src/gallium/auxiliary/gallivm/lp_bld_debug.cpp b/src/gallium/auxiliary/gallivm/lp_bld_debug.cpp index 93505f3da45..af50fcc1425 100644 --- a/src/gallium/auxiliary/gallivm/lp_bld_debug.cpp +++ b/src/gallium/auxiliary/gallivm/lp_bld_debug.cpp @@ -81,8 +81,12 @@ lp_check_alignment(const void *ptr, unsigned alignment) class raw_debug_ostream : public llvm::raw_ostream { +private: uint64_t pos; +public: + raw_debug_ostream() : pos(0) { } + void write_impl(const char *Ptr, size_t Size); #if HAVE_LLVM >= 0x207