From: Thomas Jarosch Date: Mon, 17 Oct 2011 08:46:30 +0000 (+0200) Subject: Fix initialization order X-Git-Tag: v2.6~40 X-Git-Url: http://developer.intra2net.com/git/?a=commitdiff_plain;h=5a354dce8ff35b12a3a05583d431fc8de9dd3ded;p=libi2ncommon Fix initialization order --- diff --git a/src/tmpfstream.hpp b/src/tmpfstream.hpp index 6760ccd..f3f5eb0 100644 --- a/src/tmpfstream.hpp +++ b/src/tmpfstream.hpp @@ -82,7 +82,9 @@ public: * @brief Constructs an unopened tmpfstreamTempl. */ tmpfstreamTempl() - : unlinked(false), fd(-1), bio::stream() + : bio::stream() + , unlinked(false) + , fd(-1) { } /** @@ -98,7 +100,9 @@ public: tmpfstreamTempl(const std::string& tmpnametemplate, std::ios_base::open_mode mode = std::ios_base::out, int buffer_size = -1 , int pback_size = -1) - : unlinked(false), fd(-1), bio::stream() + : bio::stream() + , unlinked(false) + , fd(-1) { open(tmpnametemplate,mode,buffer_size,pback_size); } @@ -184,10 +188,11 @@ public: * @brief Constructs an unopened tmpfcopystreamTempl. */ tmpfcopystreamTempl() - : full_sync(default_full_sync), - filemode_on_close(default_filemode_on_close), - UserOnClose(), GroupOnClose(), - tmpfstreamTempl() + : tmpfstreamTempl() + , full_sync(default_full_sync) + , filemode_on_close(default_filemode_on_close) + , UserOnClose() + , GroupOnClose() { } /** @@ -203,12 +208,12 @@ public: tmpfcopystreamTempl(const std::string& filename, std::ios_base::open_mode mode = std::ios_base::out, int buffer_size = -1 , int pback_size = -1) - : full_sync(default_full_sync), - filemode_on_close(default_filemode_on_close), - UserOnClose(), GroupOnClose(), - originalfilename(filename), - tmpfstreamTempl - (filename+default_template_suffix,mode,buffer_size,pback_size) + : tmpfstreamTempl(filename+default_template_suffix,mode,buffer_size,pback_size) + , originalfilename(filename) + , full_sync(default_full_sync) + , filemode_on_close(default_filemode_on_close) + , UserOnClose() + , GroupOnClose() { } /** @@ -228,12 +233,12 @@ public: const std::string& tmpnametemplate, std::ios_base::open_mode mode = std::ios_base::out, int buffer_size = -1 , int pback_size = -1) - : full_sync(default_full_sync), - filemode_on_close(default_filemode_on_close), - UserOnClose(), GroupOnClose(), - originalfilename(filename), - tmpfstreamTempl - (tmpnametemplate,mode,buffer_size,pback_size) + : tmpfstreamTempl(tmpnametemplate,mode,buffer_size,pback_size) + , originalfilename(filename) + , full_sync(default_full_sync) + , filemode_on_close(default_filemode_on_close) + , UserOnClose() + , GroupOnClose() { } ~tmpfcopystreamTempl()