}
if (d->ShowModal () == wxID_OK) {
- FILE* f = fopen_boost (path_from_file_dialog (d, "pem"), "w");
+ boost::filesystem::path path (wx_to_std(d->GetPath()));
+ FILE* f = fopen_boost (path, "w");
if (!f) {
- throw OpenFileError (wx_to_std (d->GetPath ()), errno, false);
+ throw OpenFileError (path, errno, false);
}
string const s = j->certificate (true);
);
if (d->ShowModal () == wxID_OK) {
- FILE* f = fopen_boost (path_from_file_dialog (d, "pem"), "w");
+ boost::filesystem::path path (wx_to_std(d->GetPath()));
+ FILE* f = fopen_boost (path, "w");
if (!f) {
- throw OpenFileError (wx_to_std (d->GetPath ()), errno, false);
+ throw OpenFileError (path, errno, false);
}
string const s = _get()->key().get ();
);
if (d->ShowModal () == wxID_OK) {
- FILE* f = fopen_boost (path_from_file_dialog (d, "dom"), "w");
+ boost::filesystem::path path (wx_to_std(d->GetPath()));
+ FILE* f = fopen_boost (path, "w");
if (!f) {
- throw OpenFileError (wx_to_std (d->GetPath ()), errno, false);
+ throw OpenFileError (path, errno, false);
}
string const chain = Config::instance()->decryption_chain()->chain();
);
if (d->ShowModal () == wxID_OK) {
- FILE* f = fopen_boost (path_from_file_dialog (d, "pem"), "w");
+ boost::filesystem::path path (wx_to_std(d->GetPath()));
+ FILE* f = fopen_boost (path, "w");
if (!f) {
- throw OpenFileError (wx_to_std (d->GetPath ()), errno, false);
+ throw OpenFileError (path, errno, false);
}
string const s = Config::instance()->decryption_chain()->chain();
);
if (d->ShowModal () == wxID_OK) {
- FILE* f = fopen_boost (path_from_file_dialog (d, "pem"), "w");
+ boost::filesystem::path path (wx_to_std(d->GetPath()));
+ FILE* f = fopen_boost (path, "w");
if (!f) {
- throw OpenFileError (wx_to_std (d->GetPath ()), errno, false);
+ throw OpenFileError (path, errno, false);
}
string const s = Config::instance()->decryption_chain()->leaf().certificate (true);
fwrite (s.c_str(), 1, s.length(), f);
fclose (f);
}
+
d->Destroy ();
}