From 8be02be08bf6a7227e2ab6a5443b63f3a155e2a9 Mon Sep 17 00:00:00 2001 From: FaramosCZ Date: Wed, 28 Nov 2018 14:16:52 +0100 Subject: [PATCH] Fix USE_AFTER_FREE (CWE-672) The file will be closed on line 540 --- sql/wsrep_binlog.cc | 1 - 1 file changed, 1 deletion(-) diff --git a/sql/wsrep_binlog.cc b/sql/wsrep_binlog.cc index c7674cd0169..39c77133f02 100644 --- a/sql/wsrep_binlog.cc +++ b/sql/wsrep_binlog.cc @@ -506,7 +506,6 @@ void wsrep_dump_rbr_buf_with_header(THD *thd, const void *rbr_buf, if (init_io_cache(&cache, file, 0, WRITE_CACHE, 0, 0, MYF(MY_WME | MY_NABP))) { - mysql_file_close(file, MYF(MY_WME)); goto cleanup2; }