Mercurial > hg > orthanc
comparison OrthancServer/main.cpp @ 684:96d8410c56cd
newlines
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Thu, 30 Jan 2014 16:58:03 +0100 |
parents | 5425bb6f1ea5 |
children | b01cc78caba4 |
comparison
equal
deleted
inserted
replaced
683:7bc5ccc550a1 | 684:96d8410c56cd |
---|---|
283 if (boost::starts_with(argv[i], "--config=")) | 283 if (boost::starts_with(argv[i], "--config=")) |
284 { | 284 { |
285 std::string configurationSample; | 285 std::string configurationSample; |
286 GetFileResource(configurationSample, EmbeddedResources::CONFIGURATION_SAMPLE); | 286 GetFileResource(configurationSample, EmbeddedResources::CONFIGURATION_SAMPLE); |
287 | 287 |
288 #if defined(_WIN32) | |
289 // Replace UNIX newlines with DOS newlines | |
290 boost::replace_all(configurationSample, "\n", "\r\n"); | |
291 #endif | |
292 | |
288 std::string target = std::string(argv[i]).substr(9); | 293 std::string target = std::string(argv[i]).substr(9); |
289 std::ofstream f(target.c_str()); | 294 std::ofstream f(target.c_str()); |
290 f << configurationSample; | 295 f << configurationSample; |
291 f.close(); | 296 f.close(); |
292 return 0; | 297 return 0; |