From: Peter Howkins Date: Wed, 4 Jul 2018 00:20:03 +0000 (+0100) Subject: dtcm: Coverity 88902 X-Git-Tag: 2.3.0a~218 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=bdc3ee7f436217a7f6c785dccdff1a8cfbb97f23;p=oweals%2Fcde.git dtcm: Coverity 88902 --- diff --git a/cde/programs/dtcm/server/cmscalendar.c b/cde/programs/dtcm/server/cmscalendar.c index 54552795..8858732c 100644 --- a/cde/programs/dtcm/server/cmscalendar.c +++ b/cde/programs/dtcm/server/cmscalendar.c @@ -1008,7 +1008,7 @@ get_file_owner(char *calname, char **owner) if (res == 0) { if (pw = getpwuid(info.st_uid)) - strcpy(buf, pw->pw_name); + snprintf(buf, sizeof(buf), "%s", pw->pw_name); else return (CSA_E_FAILURE); } else