Reformat
This commit is contained in:
parent
aa512aa4af
commit
a4f6c72e1d
1 changed files with 37 additions and 44 deletions
17
src/main.cpp
17
src/main.cpp
|
@ -1,24 +1,20 @@
|
|||
#include <3ds.h>
|
||||
#include <matrixclient.h>
|
||||
#include <memorystore.h>
|
||||
#include <olm/olm.h>
|
||||
#include <olm/account.hh>
|
||||
#include <cstring>
|
||||
#include <filesystem>
|
||||
#include <fstream>
|
||||
#include <iostream>
|
||||
#include <memorystore.h>
|
||||
#include <olm/account.hh>
|
||||
|
||||
#define PREFIX_DIRECTORY "./matrix-storage"
|
||||
#define TOKEN_FILENAME "token"
|
||||
#define DEVICE_ID "XREVXEDLHU"
|
||||
|
||||
class Store : public Matrix::Store {
|
||||
void setSyncToken(std::string token) override {
|
||||
|
||||
}
|
||||
std::string getSyncToken() override {
|
||||
return "";
|
||||
}
|
||||
void setSyncToken(std::string token) override {} //TODO store in file
|
||||
std::string getSyncToken() override { return ""; }
|
||||
void setFilterId(std::string filterId) override {}
|
||||
std::string getFilterId() override { return ""; }
|
||||
};
|
||||
|
@ -45,7 +41,6 @@ void generate_otk(olm::Account& acc){
|
|||
generate_otk(acc, otkcount);
|
||||
}
|
||||
|
||||
|
||||
void generate_device_key(olm::Account& acc) {
|
||||
size_t len = acc.new_account_random_length();
|
||||
std::unique_ptr<uint8_t[]> random = std::make_unique<uint8_t[]>(len);
|
||||
|
@ -226,7 +221,6 @@ void load_account(Matrix::Client& client, olm::Account& acc){
|
|||
}
|
||||
}
|
||||
|
||||
|
||||
int main() {
|
||||
fsInit();
|
||||
gfxInitDefault();
|
||||
|
@ -289,8 +283,7 @@ int main() {
|
|||
});
|
||||
client.startSyncLoop();
|
||||
}
|
||||
wrong:
|
||||
;
|
||||
wrong:;
|
||||
}
|
||||
client.stopSyncLoop();
|
||||
// DO NOT LOGOUT, KEEP ENCRYPTION KEYS
|
||||
|
|
Loading…
Reference in a new issue