test/crashdump_test.cc
author Krista Bennett <krista@pep-project.org>
Fri, 19 Jan 2018 14:12:02 +0100
changeset 2418 05678e77bc6a
parent 1513 e7f7e42385b5
permissions -rw-r--r--
fixed update_identity call that could be called on a myself value in outgoing_message_rating
vb@1513
     1
// This file is under GNU General Public License 3.0
vb@1513
     2
// see LICENSE.txt
vb@1513
     3
vb@452
     4
#include <iostream>
vb@452
     5
#include <string>
vb@452
     6
#include <assert.h>
vb@452
     7
#include "pEpEngine.h"
vb@452
     8
vb@452
     9
using namespace std;
vb@452
    10
vb@452
    11
int main() {
vb@455
    12
    cout << "\n*** crashdump_test ***\n\n";
vb@452
    13
vb@452
    14
    PEP_SESSION session;
vb@452
    15
    
vb@452
    16
    cout << "calling init()\n";
vb@452
    17
    PEP_STATUS status1 = init(&session);   
vb@452
    18
    assert(status1 == PEP_STATUS_OK);
vb@452
    19
    assert(session);
vb@452
    20
    cout << "init() completed.\n";
vb@452
    21
vb@452
    22
    // MODULE test code
vb@452
    23
vb@452
    24
    char *text;
vb@455
    25
    PEP_STATUS status2 = get_crashdump_log(session, 0, &text);
vb@452
    26
    assert(status2 == PEP_STATUS_OK);
vb@452
    27
    cout << text;
vb@452
    28
vb@452
    29
    cout << "calling release()\n";
vb@452
    30
    release(session);
vb@452
    31
    return 0;
vb@452
    32
}
vb@452
    33