don't use sizeof(pointer)

git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@14925 ec53bebd-3082-4978-b11e-865c3cabbd6b
This commit is contained in:
Love Hörnquist Åstrand
2005-04-24 18:56:55 +00:00
parent 17d24b0507
commit a6a96fbc46

View File

@@ -107,7 +107,7 @@ char_class_passwd_quality (krb5_context context,
len = pwd->length + 1;
pw = malloc(len);
if (pw == NULL) {
strlcpy(message, "out of memory", sizeof(message));
strlcpy(message, "out of memory", length);
return 1;
}
strlcpy(pw, pwd->data, len);
@@ -166,7 +166,7 @@ external_passwd_quality (krb5_context context,
ret = krb5_unparse_name(context, principal, &p);
if (ret) {
strlcpy(message, "out of memory", sizeof(message));
strlcpy(message, "out of memory", length);
return 1;
}