aboutsummaryrefslogtreecommitdiffstats
path: root/main/nagios-plugins/check_mysql_query-fix-use-after-free.patch
diff options
context:
space:
mode:
Diffstat (limited to 'main/nagios-plugins/check_mysql_query-fix-use-after-free.patch')
-rw-r--r--main/nagios-plugins/check_mysql_query-fix-use-after-free.patch33
1 files changed, 0 insertions, 33 deletions
diff --git a/main/nagios-plugins/check_mysql_query-fix-use-after-free.patch b/main/nagios-plugins/check_mysql_query-fix-use-after-free.patch
deleted file mode 100644
index 0f9a2784a58..00000000000
--- a/main/nagios-plugins/check_mysql_query-fix-use-after-free.patch
+++ /dev/null
@@ -1,33 +0,0 @@
-From: simon-alpine@fraho.eu
-Subject: mysql_check_query crashes on alpine 3.13 after accessing free'd data
-Upstream: reported
-
-see https://gitlab.alpinelinux.org/alpine/aports/-/issues/12601
-and https://github.com/nagios-plugins/nagios-plugins/issues/602
-
---- a/plugins/check_mysql_query.c
-+++ b/plugins/check_mysql_query.c
-@@ -143,17 +143,17 @@
- die (STATE_CRITICAL, "QUERY %s: Fetch row error - %s\n", _("CRITICAL"), error);
- }
-
-- /* free the result */
-- mysql_free_result (res);
--
-- /* close the connection */
-- mysql_close (&mysql);
--
- if (! is_numeric(row[0])) {
- die (STATE_CRITICAL, "QUERY %s: %s - '%s'\n", _("CRITICAL"), _("Is not a numeric"), row[0]);
- }
-
- value = strtod(row[0], NULL);
-+
-+ /* free the result */
-+ mysql_free_result (res);
-+
-+ /* close the connection */
-+ mysql_close (&mysql);
-
- if (verbose >= 3)
- printf("mysql result: %f\n", value);