Import of pkgsrc-2016Q3

This commit is contained in:
2016-11-18 22:39:22 +01:00
committed by sambuc
parent 9d819b6d54
commit 1242aa1e36
35952 changed files with 949747 additions and 377081 deletions
+24
View File
@@ -0,0 +1,24 @@
$NetBSD: patch-src_access.c,v 1.2 2015/11/22 17:17:33 dholland Exp $
Fix bounding errors detected by OpenBSD's compiler.
--- src/access.c~ 2006-05-11 03:44:52.000000000 +0000
+++ src/access.c
@@ -341,7 +341,7 @@ nickreadmsg(int forWhom)
strncpy(from, data.data, data.size);
from[data.size] = '\0';
} else
- strlcpy(from, "Server", LINE_SIZE);
+ strlcpy(from, "Server", sizeof(from));
userdb->del(userdb, &key, 0);
snprintf(kbuf, KEY_SIZE, "%s.message%d", u_tab[forWhom].nickname, i);
@@ -581,7 +581,7 @@ nickwrite (int forWhom, const char *pass
snprintf(line, LINE_SIZE, "Nick registered");
sends_cmdout(forWhom, line);
- strlcpy(u_tab[forWhom].realname, "registered", LINE_SIZE);
+ strlcpy(u_tab[forWhom].realname, "registered", sizeof(u_tab[forWhom].realname));
strlcpy(u_tab[forWhom].password, password, MAX_PASSWDLEN+1);
nickwritetime(forWhom, 0);
}
+15
View File
@@ -0,0 +1,15 @@
$NetBSD: patch-src_s__info.c,v 1.1 2015/11/07 22:00:16 dholland Exp $
Fix bounding errors detected by OpenBSD's compiler.
--- src/s_info.c~ 2006-05-11 03:44:53.000000000 +0000
+++ src/s_info.c
@@ -18,7 +18,7 @@ s_info(int n, int argc)
int TheirIndex;
if (argc == 2) {
- strlcpy(TheirName, getword(fields[1]), 20);
+ strlcpy(TheirName, getword(fields[1]), sizeof(TheirName));
TheirIndex = find_user(TheirName);