Browse Source

Merge branch 'minor-fixes' into release-3.10

Merge-request: !1349
Brad King 8 years ago
parent
commit
09a3a1cb9f

+ 1 - 1
Source/cmGeneratorTarget.cxx

@@ -4654,7 +4654,7 @@ void cmGeneratorTarget::ComputeLinkInterfaceLibraries(
         "INTERFACE_LINK_LIBRARIES:\n"
         "  " << newExplicitLibraries << "\n" <<
         linkIfaceProp << ":\n"
-        "  " << (explicitLibraries ? explicitLibraries : "(empty)") << "\n";
+        "  " << explicitLibraries << "\n";
       /* clang-format on */
       this->LocalGenerator->IssueMessage(cmake::AUTHOR_WARNING, w.str());
       this->PolicyWarnedCMP0022 = true;

+ 3 - 3
Source/cmInstallCommandArguments.cxx

@@ -39,7 +39,7 @@ const std::string& cmInstallCommandArguments::GetDestination() const
   if (this->GenericArguments != nullptr) {
     return this->GenericArguments->GetDestination();
   }
-  return this->EmptyString;
+  return EmptyString;
 }
 
 const std::string& cmInstallCommandArguments::GetComponent() const
@@ -65,7 +65,7 @@ const std::string& cmInstallCommandArguments::GetRename() const
   if (this->GenericArguments != nullptr) {
     return this->GenericArguments->GetRename();
   }
-  return this->EmptyString;
+  return EmptyString;
 }
 
 const std::string& cmInstallCommandArguments::GetPermissions() const
@@ -76,7 +76,7 @@ const std::string& cmInstallCommandArguments::GetPermissions() const
   if (this->GenericArguments != nullptr) {
     return this->GenericArguments->GetPermissions();
   }
-  return this->EmptyString;
+  return EmptyString;
 }
 
 bool cmInstallCommandArguments::GetOptional() const

+ 1 - 1
Source/cmProcessTools.cxx

@@ -38,7 +38,7 @@ void cmProcessTools::RunProcess(struct cmsysProcess_s* cp, OutputParser* out,
   if (err) {
     processOutput.DecodeText(std::string(), strdata, 2);
     if (!strdata.empty()) {
-      out->Process(strdata.c_str(), int(strdata.size()));
+      err->Process(strdata.c_str(), int(strdata.size()));
     }
   }
   cmsysProcess_WaitForExit(cp, nullptr);

+ 3 - 1
Source/cmcmd.cxx

@@ -1556,11 +1556,13 @@ struct NumberFormatter
 std::ostream& operator<<(std::ostream& stream,
                          NumberFormatter const& formatter)
 {
+  auto const& flags = stream.flags();
   if (formatter.Format == FORMAT_DECIMAL) {
-    stream << formatter.Value;
+    stream << std::dec << formatter.Value;
   } else {
     stream << "0x" << std::hex << formatter.Value;
   }
+  stream.flags(flags);
   return stream;
 }
 static bool RunCommand(const char* comment, std::vector<std::string>& command,