openbsd-ports/www/privoxy/patches/patch-actions_c
sturm 6035b15ee1 update to 3.0.2
- fixes two memory leaks, one serious
- quite some filter changes, upgraders beware!
- for details, see http://www.privoxy.org/announce.txt

from MAINTAINER
2003-04-01 20:52:59 +00:00

22 lines
798 B
Plaintext

$OpenBSD: patch-actions_c,v 1.2 2003/04/01 20:52:59 sturm Exp $
--- actions.c.orig Fri Feb 28 07:52:10 2003
+++ actions.c Sat Mar 29 18:17:02 2003
@@ -1206,7 +1206,7 @@ static int load_one_actions_file(struct
init_action(cur_action);
/* trim { */
- strcpy(actions_buf, buf + 1);
+ strlcpy(actions_buf, buf + 1, sizeof(actions_buf));
/* check we have a trailing } and then trim it */
end = actions_buf + strlen(actions_buf) - 1;
@@ -1306,7 +1306,7 @@ static int load_one_actions_file(struct
new_alias->name = strdup(buf);
- strcpy(actions_buf, start);
+ strlcpy(actions_buf, start, sizeof(actions_buf));
if (get_actions(actions_buf, alias_list, new_alias->action))
{