Esempio n. 1
0
void exit_toxic_success(Tox *m)
{
    store_data(m, DATA_FILE);
    memset(&user_password, 0, sizeof(struct user_password));
    kill_all_file_transfers(m);
    kill_all_windows(m);
    terminate_notify();

#ifdef AUDIO
#ifdef VIDEO
    terminate_video();
#endif /* VIDEO */
    terminate_audio();
#endif /* AUDIO */

    free_global_data();
    tox_kill(m);
    endwin();
    curl_global_cleanup();

#ifdef X11
    /* We have to terminate xtra last coz reasons
     * Please don't call this anywhere else coz trust me
     */
    terminate_xtra();
#endif /* X11 */

    exit(EXIT_SUCCESS);
}
Esempio n. 2
0
void exit_toxic_success(Tox *m)
{
    store_data(m, DATA_FILE);
    close_all_file_senders(m);
    kill_all_windows();

    free(DATA_FILE);
    free(user_settings_);

#ifdef _SOUND_NOTIFY
    notify(NULL, self_log_out, NT_ALWAYS);
#endif /* _SOUND_NOTIFY */
    terminate_notify();
#ifdef _AUDIO
    terminate_audio();
#endif /* _AUDIO */
    tox_kill(m);
    endwin();
    exit(EXIT_SUCCESS);
}