From 16674ad141661ea77b5903b1cba0716bd19ea7d2 Mon Sep 17 00:00:00 2001 From: Sebastian Wick Date: Mon, 2 Apr 2012 14:42:01 +0200 Subject: [PATCH] open file for writing AFTER reading it :) --- apps/mwiniimporter/main.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apps/mwiniimporter/main.cpp b/apps/mwiniimporter/main.cpp index 43b17b76a..836f84eb0 100644 --- a/apps/mwiniimporter/main.cpp +++ b/apps/mwiniimporter/main.cpp @@ -47,7 +47,6 @@ int main(int argc, char *argv[]) { MwIniImporter importer; importer.setVerbose(vm.count("verbose")); - boost::iostreams::stream file(outputFile); MwIniImporter::multistrmap ini = importer.loadIniFile(iniFile); MwIniImporter::multistrmap cfg = importer.loadCfgFile(cfgFile); @@ -59,6 +58,7 @@ int main(int argc, char *argv[]) { } std::cout << "write to: " << outputFile << std::endl; + boost::iostreams::stream file(outputFile); importer.writeToFile(file, cfg); return 0;