]> granicus.if.org Git - icinga2/commitdiff
Fix the build error for real
authorJean Flach <jean-marcel.flach@netways.de>
Thu, 19 Feb 2015 16:44:42 +0000 (17:44 +0100)
committerJean Flach <jean-marcel.flach@netways.de>
Thu, 19 Feb 2015 16:44:42 +0000 (17:44 +0100)
lib/cli/troubleshootcollectcommand.cpp

index f243424f1d2d644fcd1400b5b20b9948c914b68d..6ffc76e3818f3628023e4f40556046029416e37a 100644 (file)
@@ -357,10 +357,9 @@ void TroubleshootCollectCommand::CheckObjectFile(const String& objectfile, InfoL
 
                bool first = true;
                
-               if (print)
-                       ObjectListUtility::PrintObject(std::ostream(NULL), first, message, type_count, "", "");
-               else
-                       ObjectListUtility::PrintObject(std::ostream(NULL), first, message, type_count, "", "");
+               std::ofstream badstream;
+               
+               ObjectListUtility::PrintObject(badstream, first, message, type_count, "", "");
                
                Dictionary::Ptr object = JsonDecode(message);
                Dictionary::Ptr properties = object->Get("properties");