From c25296e65a44444c8f8d88b534b001c62aa99966 Mon Sep 17 00:00:00 2001 From: Jfreegman Date: Sat, 30 Nov 2013 16:09:45 -0500 Subject: [PATCH] fixes --- src/chat.c | 3 +-- src/main.c | 8 +++----- src/windows.c | 3 +-- 3 files changed, 5 insertions(+), 9 deletions(-) diff --git a/src/chat.c b/src/chat.c index beeeb96..d56d482 100644 --- a/src/chat.c +++ b/src/chat.c @@ -17,7 +17,6 @@ extern char *DATA_FILE; extern int store_data(Tox *m, char *path); -extern int num_groupchats; extern FileSender file_senders[MAX_FILES]; extern ToxicFriend friends[MAX_FRIENDS_NUM]; @@ -184,7 +183,7 @@ static void chat_onFileControl(ToxWindow *self, Tox *m, int num, uint8_t receive wprintw(ctx->history, "File transfer for '%s' accepted.\n", filename); break; case TOX_FILECONTROL_PAUSE: - wprintw(ctx->history, "File transfer for '%s' paused.\n", filename); + // wprintw(ctx->history, "File transfer for '%s' paused.\n", filename); break; case TOX_FILECONTROL_KILL: wprintw(ctx->history, "File transfer for '%s' failed.\n", filename); diff --git a/src/main.c b/src/main.c index db3cb92..b0015bf 100644 --- a/src/main.c +++ b/src/main.c @@ -332,12 +332,10 @@ static void load_data(Tox *m, char *path) tox_load(m, buf, len); uint32_t i = 0; - uint8_t name[TOX_MAX_NAME_LENGTH]; - while (tox_get_name(m, i, name) != -1) { - on_friendadded(m, i); - i++; - } + + while (tox_get_name(m, i, name) != -1) + on_friendadded(m, i++); free(buf); fclose(fd); diff --git a/src/windows.c b/src/windows.c index 587b869..7871b33 100644 --- a/src/windows.c +++ b/src/windows.c @@ -13,7 +13,6 @@ extern char *DATA_FILE; static ToxWindow windows[MAX_WINDOWS_NUM]; static ToxWindow *active_window; -static int num_windows; extern ToxWindow *prompt; @@ -359,4 +358,4 @@ int num_active_windows(void) } return count; -} \ No newline at end of file +}