author | Edouard Tisserant |
Thu, 09 Jun 2016 19:19:46 +0200 | |
branch | import_own_key |
changeset 727 | 382718692559 |
parent 513 | 2b4337ce0819 |
child 1513 | e7f7e42385b5 |
permissions | -rw-r--r-- |
1 #include <iostream>
2 #include <string>
3 #include <assert.h>
4 #include "message_api.h"
6 using namespace std;
8 int main() {
9 cout << "\n*** pgp_binary_test ***\n\n";
11 PEP_SESSION session;
13 cout << "calling init()\n";
14 PEP_STATUS status1 = init(&session);
15 assert(status1 == PEP_STATUS_OK);
16 assert(session);
17 cout << "init() completed.\n";
19 // pgp_binary test code
21 const char *path;
22 PEP_STATUS status2 = get_binary_path(PEP_crypt_OpenPGP, &path);
23 assert(status2 == PEP_STATUS_OK);
24 #ifdef USE_GPG
25 assert(path);
26 #endif
27 if (path)
28 cout << "PGP binary at " << path << "\n";
29 else
30 cout << "no PGP binary path available\n";
32 cout << "calling release()\n";
33 release(session);
34 return 0;
35 }