Example #1
0
File: oor.c Project: biels/oor
void
exit_cleanup(void) {
    OOR_LOG(LDBG_2,"Exit Cleanup");

#ifndef ANDROID
    pid_file_remove();
#endif
    // Order is important
    ctrl_destroy(lctrl);

    if (data_plane){
        data_plane->datap_uninit();
    }

    ifaces_destroy();

    sockmstr_destroy(smaster);

    oor_timers_destroy();

    htable_ptrs_destroy(ptrs_to_timers_ht);
    htable_nonces_destroy(nonces_ht);

    close_log_file();
#ifndef VPNAPI
    OOR_LOG(LINF,"Exiting ...");
    exit(EXIT_SUCCESS);
#else
    jni_uninit();
#endif

}
Example #2
0
void
exit_cleanup(void) {
    LMLOG(LDBG_2,"Exit Cleanup");

    //lmapi_end(&lmapi_connection);
#ifndef ANDROID
    pid_file_remove();
#endif

    ctrl_destroy(lctrl);

    ifaces_destroy();

    if (!data_plane){
        data_plane->datap_uninit();
    }

    sockmstr_destroy(smaster);

    lmtimers_destroy();

    htable_ptrs_destroy(ptrs_to_timers_ht);
    htable_nonces_destroy(nonces_ht);

    close_log_file();
#ifndef VPNAPI
    LMLOG(LINF,"Exiting ...");
    exit(EXIT_SUCCESS);
#else
    jni_uninit();
#endif

}