summaryrefslogtreecommitdiffstats
path: root/plugins
diff options
context:
space:
mode:
Diffstat (limited to 'plugins')
-rw-r--r--plugins/Makefile.am2
-rw-r--r--plugins/check_mysql.c4
-rw-r--r--plugins/check_mysql_query.c4
-rw-r--r--plugins/t/check_mysql.t2
4 files changed, 7 insertions, 5 deletions
diff --git a/plugins/Makefile.am b/plugins/Makefile.am
index 7f9d745..9a1f6d0 100644
--- a/plugins/Makefile.am
+++ b/plugins/Makefile.am
@@ -63,7 +63,9 @@ check_ldap_LDADD = $(NETLIBS) $(LDAPLIBS)
63check_load_LDADD = $(BASEOBJS) popen.o 63check_load_LDADD = $(BASEOBJS) popen.o
64check_mrtg_LDADD = $(BASEOBJS) 64check_mrtg_LDADD = $(BASEOBJS)
65check_mrtgtraf_LDADD = $(BASEOBJS) 65check_mrtgtraf_LDADD = $(BASEOBJS)
66check_mysql_CPPFLAGS = $(MYSQLINCLUDE)
66check_mysql_LDADD = $(NETLIBS) $(MYSQLLIBS) 67check_mysql_LDADD = $(NETLIBS) $(MYSQLLIBS)
68check_mysql_query_CPPFLAGS = $(MYSQLINCLUDE)
67check_mysql_query_LDADD = $(NETLIBS) $(MYSQLLIBS) 69check_mysql_query_LDADD = $(NETLIBS) $(MYSQLLIBS)
68check_nagios_LDADD = $(BASEOBJS) runcmd.o 70check_nagios_LDADD = $(BASEOBJS) runcmd.o
69check_nt_LDADD = $(NETLIBS) 71check_nt_LDADD = $(NETLIBS)
diff --git a/plugins/check_mysql.c b/plugins/check_mysql.c
index 92ac7ff..9d547dd 100644
--- a/plugins/check_mysql.c
+++ b/plugins/check_mysql.c
@@ -25,8 +25,8 @@ const char *email = "nagiosplug-devel@lists.sourceforge.net";
25#include "utils.h" 25#include "utils.h"
26#include "netutils.h" 26#include "netutils.h"
27 27
28#include <mysql/mysql.h> 28#include <mysql.h>
29#include <mysql/errmsg.h> 29#include <errmsg.h>
30 30
31char *db_user = NULL; 31char *db_user = NULL;
32char *db_host = NULL; 32char *db_host = NULL;
diff --git a/plugins/check_mysql_query.c b/plugins/check_mysql_query.c
index 321af7a..b542fb4 100644
--- a/plugins/check_mysql_query.c
+++ b/plugins/check_mysql_query.c
@@ -22,8 +22,8 @@ const char *email = "nagiosplug-devel@lists.sourceforge.net";
22#include "utils.h" 22#include "utils.h"
23#include "netutils.h" 23#include "netutils.h"
24 24
25#include <mysql/mysql.h> 25#include <mysql.h>
26#include <mysql/errmsg.h> 26#include <errmsg.h>
27 27
28char *db_user = NULL; 28char *db_user = NULL;
29char *db_host = NULL; 29char *db_host = NULL;
diff --git a/plugins/t/check_mysql.t b/plugins/t/check_mysql.t
index 78413c6..852926a 100644
--- a/plugins/t/check_mysql.t
+++ b/plugins/t/check_mysql.t
@@ -48,7 +48,7 @@ SKIP: {
48 $result = NPTest->testCmd("./check_mysql -H $mysqlserver $mysql_login_details"); 48 $result = NPTest->testCmd("./check_mysql -H $mysqlserver $mysql_login_details");
49 cmp_ok( $result->return_code, '==', 0, "Login okay"); 49 cmp_ok( $result->return_code, '==', 0, "Login okay");
50 50
51 $result = NPTest->testCmd("./check_mysql -H $mysqlserver -u dummy"); 51 $result = NPTest->testCmd("./check_mysql -H $mysqlserver -u dummy -pdummy");
52 cmp_ok( $result->return_code, '==', 2, "Login failure"); 52 cmp_ok( $result->return_code, '==', 2, "Login failure");
53 like( $result->output, $bad_login_output, "Expected login failure message"); 53 like( $result->output, $bad_login_output, "Expected login failure message");
54 54