aboutsummaryrefslogtreecommitdiff
path: root/plugins
diff options
context:
space:
mode:
authorGravatar Ton Voon <tonvoon@users.sourceforge.net> 2005-04-04 18:24:12 +0000
committerGravatar Ton Voon <tonvoon@users.sourceforge.net> 2005-04-04 18:24:12 +0000
commit256673724683cefe2062bb7cefb0d622d1c34852 (patch)
tree4c9e54b42a3f46a008cdb98bb37ac4a80073d066 /plugins
parent8f81329864bdceb6bc2d1068f8fb5af1d2195916 (diff)
downloadmonitoring-plugins-256673724683cefe2062bb7cefb0d622d1c34852.tar.gz
Fix static buffer (Nikolay Sturm)
git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@1155 f882894a-f735-0410-b71e-b25c423dba1c
Diffstat (limited to 'plugins')
-rw-r--r--plugins/check_smtp.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/plugins/check_smtp.c b/plugins/check_smtp.c
index f23e5d03..3bb6cc46 100644
--- a/plugins/check_smtp.c
+++ b/plugins/check_smtp.c
@@ -76,7 +76,7 @@ int my_close(void);
char regex_expect[MAX_INPUT_BUFFER] = "";
regex_t preg;
regmatch_t pmatch[10];
-char timestamp[10] = "";
+char timestamp[20] = "";
char errbuf[MAX_INPUT_BUFFER];
int cflags = REG_EXTENDED | REG_NOSUB | REG_NEWLINE;
int eflags = 0;
@@ -665,7 +665,7 @@ check_certificate (X509 ** certificate)
days_left = (mktime (&stamp) - time (NULL)) / 86400;
snprintf
- (timestamp, 16, "%02d/%02d/%04d %02d:%02d",
+ (timestamp, sizeof(timestamp), "%02d/%02d/%04d %02d:%02d",
stamp.tm_mon + 1,
stamp.tm_mday, stamp.tm_year + 1900, stamp.tm_hour, stamp.tm_min);