add field limit for sscanf call (fix libc versions older than 2.13-25)
This commit is contained in:
parent
c9c8daac45
commit
f2f4153d00
1 changed files with 1 additions and 1 deletions
|
@ -560,7 +560,7 @@ void interpreter_chat_mode (char *line) {
|
|||
}
|
||||
if (!strncmp (line, "/history", 8)) {
|
||||
int limit = 40;
|
||||
sscanf (line, "/history %d", &limit);
|
||||
sscanf (line, "/history %99d", &limit);
|
||||
if (limit < 0 || limit > 1000) { limit = 40; }
|
||||
do_get_history (chat_mode_id, limit);
|
||||
return;
|
||||
|
|
Loading…
Add table
Reference in a new issue