From: Peter Howkins Date: Wed, 4 Jul 2018 00:22:34 +0000 (+0100) Subject: dtcm: Coverity 88481 X-Git-Tag: 2.3.0a~217 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=3b85e48a68ca7b0ed838f2a6f2c20f11d24a2373;p=oweals%2Fcde.git dtcm: Coverity 88481 --- diff --git a/cde/programs/dtcm/server/parser.y b/cde/programs/dtcm/server/parser.y index 0b8646f5..a89ff0eb 100644 --- a/cde/programs/dtcm/server/parser.y +++ b/cde/programs/dtcm/server/parser.y @@ -767,7 +767,7 @@ convert_2_tick(char *datestr) memset((void *)&tmstr, 0, sizeof(struct tm)); - strcpy(datebuf, datestr); + snprintf(datebuf, sizeof(datebuf), "%s", datestr); /* get week day */ ptr = strtok(datebuf, " ");