large strc{py,at}_truncate -> strlc{py,at} replacement
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@6984 ec53bebd-3082-4978-b11e-865c3cabbd6b
This commit is contained in:
@@ -145,7 +145,7 @@ otp_get_internal (void *v, OtpContext *ctx, int lockp)
|
||||
p += 4;
|
||||
memcpy (ctx->key, p, OTPKEYSIZE);
|
||||
p += OTPKEYSIZE;
|
||||
strcpy_truncate (ctx->seed, p, sizeof(ctx->seed));
|
||||
strlcpy (ctx->seed, p, sizeof(ctx->seed));
|
||||
if (lockp)
|
||||
return dbm_store (dbm, key, dat, DBM_REPLACE);
|
||||
else
|
||||
|
@@ -88,7 +88,7 @@ otp_print_hex (OtpKey key, char *str, size_t sz)
|
||||
void
|
||||
otp_print_hex_extended (OtpKey key, char *str, size_t sz)
|
||||
{
|
||||
strcpy_truncate (str, OTP_HEXPREFIX, sz);
|
||||
strlcpy (str, OTP_HEXPREFIX, sz);
|
||||
otp_print_hex (key,
|
||||
str + strlen(OTP_HEXPREFIX),
|
||||
sz - strlen(OTP_HEXPREFIX));
|
||||
@@ -97,7 +97,7 @@ otp_print_hex_extended (OtpKey key, char *str, size_t sz)
|
||||
void
|
||||
otp_print_stddict_extended (OtpKey key, char *str, size_t sz)
|
||||
{
|
||||
strcpy_truncate (str, OTP_WORDPREFIX, sz);
|
||||
strlcpy (str, OTP_WORDPREFIX, sz);
|
||||
otp_print_stddict (key,
|
||||
str + strlen(OTP_WORDPREFIX),
|
||||
sz - strlen(OTP_WORDPREFIX));
|
||||
|
Reference in New Issue
Block a user