diff options
| -rw-r--r-- | plugins/check_smtp.c | 2 | ||||
| -rw-r--r-- | plugins/check_smtp.d/config.h | 2 |
2 files changed, 3 insertions, 1 deletions
diff --git a/plugins/check_smtp.c b/plugins/check_smtp.c index 324549d4..fd492294 100644 --- a/plugins/check_smtp.c +++ b/plugins/check_smtp.c | |||
| @@ -697,6 +697,8 @@ check_smtp_config_wrapper process_arguments(int argc, char **argv) { | |||
| 697 | } else { | 697 | } else { |
| 698 | usage2(_("Invalid hostname/address"), argv[c]); | 698 | usage2(_("Invalid hostname/address"), argv[c]); |
| 699 | } | 699 | } |
| 700 | } else { | ||
| 701 | result.config.server_address = strdup("localhost"); | ||
| 700 | } | 702 | } |
| 701 | } | 703 | } |
| 702 | 704 | ||
diff --git a/plugins/check_smtp.d/config.h b/plugins/check_smtp.d/config.h index c8660445..0a6511ef 100644 --- a/plugins/check_smtp.d/config.h +++ b/plugins/check_smtp.d/config.h | |||
| @@ -52,7 +52,7 @@ typedef struct { | |||
| 52 | check_smtp_config check_smtp_config_init() { | 52 | check_smtp_config check_smtp_config_init() { |
| 53 | check_smtp_config tmp = { | 53 | check_smtp_config tmp = { |
| 54 | .server_port = SMTP_PORT, | 54 | .server_port = SMTP_PORT, |
| 55 | .server_address = strdup("localhost"), | 55 | .server_address = NULL, |
| 56 | .localhostname = NULL, | 56 | .localhostname = NULL, |
| 57 | 57 | ||
| 58 | .server_expect = SMTP_EXPECT, | 58 | .server_expect = SMTP_EXPECT, |
