From d8ffcdb0264c84a1d67a7776ad9d09f433e84682 Mon Sep 17 00:00:00 2001 From: Thomas Jarosch Date: Fri, 16 Jul 2010 14:55:20 +0200 Subject: [PATCH] Reflect initialization order in pipestream constructor: The base class is initialized before the class members --- src/pipestream.hxx | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/pipestream.hxx b/src/pipestream.hxx index 03ee60e..3dad8b6 100644 --- a/src/pipestream.hxx +++ b/src/pipestream.hxx @@ -90,7 +90,7 @@ protected: public: inpipestream(const std::string& command) - : buf(command), std::istream(&buf) + : std::istream(&buf), buf(command) {} void store_exit_status(bool *_status_set, int *_exit_status) @@ -157,7 +157,7 @@ protected: outpipebuf buf; public: outpipestream(const std::string& command) - : buf(command), std::ostream(&buf) + : std::ostream(&buf), buf(command) {} void store_exit_status(bool *_status_set, int *_exit_status) -- 1.7.1