cout << "usage: " << name << " [-o output_filename] <input_filename>" << endl;
cout << " " << name << " {--system|--session} [-o output_filename]" << endl;
cout << endl;
+ cout << "If not specified, output_filename is input_filename.serialized" << endl;
+ cout << endl;
}
int main(int argc, char *argv[])
{
BusType bus_type = BusType::SYSTEM_BUS;
bool need_input_filename = true;
- std::string output_filename = "result.dat";
+ std::string output_filename;
std::string input_filename;
int c;
}
}
+ if (output_filename.empty())
+ output_filename = input_filename + ".serialized";
+
cout << "Read from: " << input_filename << " write to: " << output_filename << endl;
ldp_xml_parser::Serializer serializer;
ofstream output(output_filename, ofstream::binary);