diff options
author | Greg Hudson <ghudson@mit.edu> | 2008-10-24 20:07:00 +0000 |
---|---|---|
committer | Greg Hudson <ghudson@mit.edu> | 2008-10-24 20:07:00 +0000 |
commit | fcf15c482b582c4f2e5dd7c6222c4e3509bbb7d6 (patch) | |
tree | 9ce89cc387b4bee641f0f25e818371b90731fdb6 /src/lib/kadm5/str_conv.c | |
parent | 4d901a092a69a69be251131174166fc661d13633 (diff) | |
download | krb5-fcf15c482b582c4f2e5dd7c6222c4e3509bbb7d6.zip krb5-fcf15c482b582c4f2e5dd7c6222c4e3509bbb7d6.tar.gz krb5-fcf15c482b582c4f2e5dd7c6222c4e3509bbb7d6.tar.bz2 |
Use strlcpy instead of strcpy in many places
ticket: 6200
status: open
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@20919 dc483132-0cff-0310-8789-dd5450dbe970
Diffstat (limited to 'src/lib/kadm5/str_conv.c')
-rw-r--r-- | src/lib/kadm5/str_conv.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/lib/kadm5/str_conv.c b/src/lib/kadm5/str_conv.c index 0d142d6..b9e58aa 100644 --- a/src/lib/kadm5/str_conv.c +++ b/src/lib/kadm5/str_conv.c @@ -221,8 +221,8 @@ krb5_input_flag_to_string(flag, buffer, buflen) size_t buflen; { if(flag < 0 || flag >= flags_table_nents) return ENOENT; /* End of list */ - if(strlen(flags_table[flag].fl_specifier) > buflen) return ENOMEM; - strcpy(buffer, flags_table[flag].fl_specifier); + if(strlcpy(buffer, flags_table[flag].fl_specifier, buflen) >= buflen) + return ENOMEM; return 0; } |