mirror of
https://github.com/Tha14/toxic.git
synced 2024-11-26 22:53:28 +01:00
make correct error message print
This commit is contained in:
parent
38f6f446c4
commit
4ffb98dcdb
@ -364,7 +364,7 @@ void cmd_nick(WINDOW *window, ToxWindow *prompt, Tox *m, int argc, char **argv)
|
|||||||
|
|
||||||
void cmd_note(WINDOW *window, ToxWindow *prompt, Tox *m, int argc, char **argv)
|
void cmd_note(WINDOW *window, ToxWindow *prompt, Tox *m, int argc, char **argv)
|
||||||
{
|
{
|
||||||
if (argc != 1) {
|
if (argc < 1) {
|
||||||
wprintw(window, "Wrong number of arguments.\n");
|
wprintw(window, "Wrong number of arguments.\n");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
@ -157,7 +157,7 @@ static void prompt_onDraw(ToxWindow *self, Tox *m)
|
|||||||
|
|
||||||
size_t i;
|
size_t i;
|
||||||
|
|
||||||
for (i = 0; i < (prompt_buf_pos); ++i) {
|
for (i = 0; i < prompt_buf_pos; ++i) {
|
||||||
if ((prompt_buf[i] == '\n') && (y != 0))
|
if ((prompt_buf[i] == '\n') && (y != 0))
|
||||||
--y;
|
--y;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user