summaryrefslogtreecommitdiffstats
path: root/Source/cmServer.cxx
diff options
context:
space:
mode:
authorDaniel Pfeifer <daniel@pfeifer-mail.de>2017-05-05 21:21:39 (GMT)
committerDaniel Pfeifer <daniel@pfeifer-mail.de>2017-05-05 22:03:47 (GMT)
commitf3e216131b7b0a889507c3c4100b298c75ad3d84 (patch)
tree7db2f8c18dd770894d1e05b5bdb07a01e8dd7a73 /Source/cmServer.cxx
parent9535823b2cff81b05e4c6b64016a95e2264ecda5 (diff)
downloadCMake-f3e216131b7b0a889507c3c4100b298c75ad3d84.zip
CMake-f3e216131b7b0a889507c3c4100b298c75ad3d84.tar.gz
CMake-f3e216131b7b0a889507c3c4100b298c75ad3d84.tar.bz2
cmServer: include what you use
Diffstat (limited to 'Source/cmServer.cxx')
-rw-r--r--Source/cmServer.cxx19
1 files changed, 7 insertions, 12 deletions
diff --git a/Source/cmServer.cxx b/Source/cmServer.cxx
index 5a71dc0..19bdd45 100644
--- a/Source/cmServer.cxx
+++ b/Source/cmServer.cxx
@@ -6,18 +6,15 @@
#include "cmServerDictionary.h"
#include "cmServerProtocol.h"
#include "cmSystemTools.h"
-#include "cmVersionMacros.h"
-#include "cmake.h"
-
-#if defined(CMAKE_BUILD_WITH_CMAKE)
#include "cm_jsoncpp_reader.h"
-#include "cm_jsoncpp_value.h"
-#endif
+#include "cm_jsoncpp_writer.h"
+#include "cmake.h"
+#include "cmsys/FStream.hxx"
#include <algorithm>
-#include <fstream>
-#include <iostream>
-#include <memory>
+#include <cassert>
+#include <cstdint>
+#include <utility>
class cmServer::DebugInfo
{
@@ -270,10 +267,8 @@ void cmServer::WriteJsonObject(const Json::Value& jsonValue,
}
if (!debug->OutputFile.empty()) {
- std::ofstream myfile;
- myfile.open(debug->OutputFile);
+ cmsys::ofstream myfile(debug->OutputFile.c_str());
myfile << result;
- myfile.close();
}
}