diff options
author | Ben Lindstrom <mouring@eviladmin.org> | 2001-01-29 08:10:11 +0000 |
---|---|---|
committer | Ben Lindstrom <mouring@eviladmin.org> | 2001-01-29 08:10:11 +0000 |
commit | 91fd62af63cc3b7660930240042e71cff85abcb2 (patch) | |
tree | 1c51df073cd7b76b6715e7008b0c7e1314b14d8f | |
parent | d53902049e467f68490aae4988e466fc9a99abee (diff) |
- stevesk@cvs.openbsd.org 2001/01/28 20:53:21
[xmalloc.c]
use size_t for strlen() return. ok markus@
-rw-r--r-- | ChangeLog | 3 | ||||
-rw-r--r-- | xmalloc.c | 4 |
2 files changed, 5 insertions, 2 deletions
@@ -14,6 +14,9 @@ | |||
14 | - stevesk@cvs.openbsd.org 2001/01/28 22:27:05 | 14 | - stevesk@cvs.openbsd.org 2001/01/28 22:27:05 |
15 | [authfile.c] | 15 | [authfile.c] |
16 | spelling. use sizeof vs. strlen(). ok markus@ | 16 | spelling. use sizeof vs. strlen(). ok markus@ |
17 | - stevesk@cvs.openbsd.org 2001/01/28 20:53:21 | ||
18 | [xmalloc.c] | ||
19 | use size_t for strlen() return. ok markus@ | ||
17 | - niklas@cvs.openbsd.org 2001/01/29 1:59:14 | 20 | - niklas@cvs.openbsd.org 2001/01/29 1:59:14 |
18 | [atomicio.h canohost.h clientloop.h deattack.h dh.h dispatch.h | 21 | [atomicio.h canohost.h clientloop.h deattack.h dh.h dispatch.h |
19 | groupaccess.c groupaccess.h hmac.h hostfile.h includes.h kex.h | 22 | groupaccess.c groupaccess.h hmac.h hostfile.h includes.h kex.h |
@@ -13,7 +13,7 @@ | |||
13 | */ | 13 | */ |
14 | 14 | ||
15 | #include "includes.h" | 15 | #include "includes.h" |
16 | RCSID("$OpenBSD: xmalloc.c,v 1.9 2001/01/21 19:06:02 markus Exp $"); | 16 | RCSID("$OpenBSD: xmalloc.c,v 1.10 2001/01/28 20:53:21 stevesk Exp $"); |
17 | 17 | ||
18 | #include "xmalloc.h" | 18 | #include "xmalloc.h" |
19 | #include "log.h" | 19 | #include "log.h" |
@@ -51,7 +51,7 @@ xfree(void *ptr) | |||
51 | char * | 51 | char * |
52 | xstrdup(const char *str) | 52 | xstrdup(const char *str) |
53 | { | 53 | { |
54 | int len = strlen(str) + 1; | 54 | size_t len = strlen(str) + 1; |
55 | 55 | ||
56 | char *cp = xmalloc(len); | 56 | char *cp = xmalloc(len); |
57 | strlcpy(cp, str, len); | 57 | strlcpy(cp, str, len); |