浏览代码

cmFileCommand: Clarify logic for populating LOG variable

The chunkDebug buffer we use to accumulate the LOG variable content
is populated if and only if a log variable was requested by the call,
but it is much clearer to check that a log variable was requested
explicitly before populating it.
Brad King 10 年之前
父节点
当前提交
7e10f1691f
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      Source/cmFileCommand.cxx

+ 1 - 1
Source/cmFileCommand.cxx

@@ -3287,7 +3287,7 @@ cmFileCommand::HandleDownloadCommand(std::vector<std::string> const& args)
       }
     }
 
-  if(!chunkDebug.empty())
+  if (!logVar.empty())
     {
     chunkDebug.push_back(0);
     this->Makefile->AddDefinition(logVar, &*chunkDebug.begin());