From a7090df74b06d6e5221c17a176b7cbadef8da478 Mon Sep 17 00:00:00 2001 From: Karen Arutyunov Date: Mon, 4 Mar 2019 17:32:49 +0300 Subject: Fix 'may be used uninitialized' GCC 8.3 warning --- libbutl/fdstream.cxx | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/libbutl/fdstream.cxx b/libbutl/fdstream.cxx index e5b2a19..2d3ca45 100644 --- a/libbutl/fdstream.cxx +++ b/libbutl/fdstream.cxx @@ -521,9 +521,11 @@ namespace butl if (non_blocking_) throw_generic_ios_failure (ENOTSUP); - // Translate ios_base value to to fdseek_mode. + // Translate ios_base::seekdir value to fdseek_mode. Note: + // ios_base::seekdir is an implementation-defined type and is not + // necessarily a enum. // - fdseek_mode m; + fdseek_mode m (fdseek_mode::set); switch (dir) { case ios_base::beg: m = fdseek_mode::set; break; -- cgit v1.1