summaryrefslogtreecommitdiff
path: root/testing/toxic/prompt.c
diff options
context:
space:
mode:
Diffstat (limited to 'testing/toxic/prompt.c')
-rw-r--r--testing/toxic/prompt.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/testing/toxic/prompt.c b/testing/toxic/prompt.c
index b84773af..1d0e0144 100644
--- a/testing/toxic/prompt.c
+++ b/testing/toxic/prompt.c
@@ -16,7 +16,7 @@
16uint8_t pending_requests[MAX_STR_SIZE][CLIENT_ID_SIZE]; // XXX 16uint8_t pending_requests[MAX_STR_SIZE][CLIENT_ID_SIZE]; // XXX
17uint8_t num_requests=0; // XXX 17uint8_t num_requests=0; // XXX
18 18
19static friendAddedFn *on_friendadded; 19static friendAddedFn *on_friendadded_cb;
20static char prompt_buf[MAX_STR_SIZE] = {0}; 20static char prompt_buf[MAX_STR_SIZE] = {0};
21static int prompt_buf_pos = 0; 21static int prompt_buf_pos = 0;
22 22
@@ -88,7 +88,7 @@ void cmd_accept(ToxWindow *self, Messenger *m, char **args)
88 wprintw(self->window, "Failed to add friend.\n"); 88 wprintw(self->window, "Failed to add friend.\n");
89 else { 89 else {
90 wprintw(self->window, "Friend accepted as: %d.\n", num); 90 wprintw(self->window, "Friend accepted as: %d.\n", num);
91 on_friendadded(m, num); 91 on_friendadded_cb(m, num);
92 } 92 }
93} 93}
94 94
@@ -152,7 +152,7 @@ void cmd_add(ToxWindow *self, Messenger *m, char **args)
152 break; 152 break;
153 default: 153 default:
154 wprintw(self->window, "Friend added as %d.\n", num); 154 wprintw(self->window, "Friend added as %d.\n", num);
155 on_friendadded(m, num); 155 on_friendadded_cb(m, num);
156 break; 156 break;
157 } 157 }
158} 158}
@@ -436,7 +436,7 @@ static void prompt_onInit(ToxWindow *self, Messenger *m)
436 436
437ToxWindow new_prompt(friendAddedFn *f) 437ToxWindow new_prompt(friendAddedFn *f)
438{ 438{
439 on_friendadded = f; 439 on_friendadded_cb = f;
440 ToxWindow ret; 440 ToxWindow ret;
441 memset(&ret, 0, sizeof(ret)); 441 memset(&ret, 0, sizeof(ret));
442 ret.onKey = &prompt_onKey; 442 ret.onKey = &prompt_onKey;