talons

Fork of Claws Mail https://www.claws-mail
Log | Files | Refs | README | LICENSE

commit cef532d7aa45b9a7ca9b036b9a21cd3a887c66b9
parent 5ad4679e5bab182ade2b3628b3e41608a5af4522
Author: wwp <subscript@free.fr>
Date:   Fri,  3 Sep 2021 09:35:39 +0200

Bogofilter: use BUFFSIZE to dimension the exchange buffer w/ bogofilter.
Use the proper buffer size (tmpbuf).

Diffstat:
Msrc/plugins/bogofilter/bogofilter.c | 4++--
1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/plugins/bogofilter/bogofilter.c b/src/plugins/bogofilter/bogofilter.c @@ -174,7 +174,7 @@ static void bogofilter_do_filter(BogoFilterData *data) GSList *cur = NULL; int total = 0, curnum = 1; gchar *file = NULL; - gchar buf[BUFSIZ]; + gchar buf[BUFFSIZE]; total = g_slist_length(data->msglist); @@ -273,7 +273,7 @@ static void bogofilter_do_filter(BogoFilterData *data) if (claws_fwrite(tmpstr, 1, strlen(tmpstr), output) < strlen(tmpstr)) { err = TRUE; } else { - while (claws_fgets(tmpbuf, sizeof(buf), input)) { + while (claws_fgets(tmpbuf, sizeof(tmpbuf), input)) { if (claws_fputs(tmpbuf, output) == EOF) { err = TRUE; break;