Fix Key::WriteToFile method being not const qualified

This commit is contained in:
Leonetienne 2022-05-27 17:04:05 +02:00
parent 5365233b43
commit 191b17c631
No known key found for this signature in database
GPG Key ID: C33879CD92E9708C
3 changed files with 3 additions and 3 deletions

View File

@ -21,7 +21,7 @@ namespace Leonetienne::GCrypt {
static Key LoadFromFile(const std::string& path);
//! Will save a keyfile
void WriteToFile(const std::string& path);
void WriteToFile(const std::string& path) const;
Key();
Key(const Key& k);

View File

@ -1,7 +1,7 @@
#ifndef GCRYPT_VERSION_H
#define GCRYPT_VERSION_H
#define GCRYPT_VERSION 0.235
#define GCRYPT_VERSION 0.236
#endif

View File

@ -50,7 +50,7 @@ namespace Leonetienne::GCrypt {
return key;
}
void Key::WriteToFile(const std::string& path) {
void Key::WriteToFile(const std::string& path) const {
// Create an ofilestream
std::ofstream ofs(path, std::ios::out | std::ios::binary);