summaryrefslogtreecommitdiff
path: root/sql/sql_load.cc
diff options
context:
space:
mode:
authorSergei Golubchik <sergii@pisem.net>2010-11-05 10:59:51 +0100
committerSergei Golubchik <sergii@pisem.net>2010-11-05 10:59:51 +0100
commitbc2e383e4a0dbc1949d5b65102e843c01237e23c (patch)
tree23bb774ead6f6cc840c11c0536f3f59c5d417aca /sql/sql_load.cc
parent4cce72a9292c98fab5628adc24c1635e315444e7 (diff)
parent4cfa91f42c4cde9c35979cd2b9837cb60213d876 (diff)
downloadmariadb-git-bc2e383e4a0dbc1949d5b65102e843c01237e23c.tar.gz
mysql-5.1 -> mysql-5.5 merge
Diffstat (limited to 'sql/sql_load.cc')
-rw-r--r--sql/sql_load.cc10
1 files changed, 4 insertions, 6 deletions
diff --git a/sql/sql_load.cc b/sql/sql_load.cc
index 15efa488173..69059961633 100644
--- a/sql/sql_load.cc
+++ b/sql/sql_load.cc
@@ -1345,6 +1345,7 @@ READ_INFO::READ_INFO(File file_par, uint tot_length, CHARSET_INFO *cs,
MYF(MY_WME)))
{
my_free(buffer); /* purecov: inspected */
+ buffer= NULL;
error=1;
}
else
@@ -1371,13 +1372,10 @@ READ_INFO::READ_INFO(File file_par, uint tot_length, CHARSET_INFO *cs,
READ_INFO::~READ_INFO()
{
- if (!error)
- {
- if (need_end_io_cache)
- ::end_io_cache(&cache);
+ if (!error && need_end_io_cache)
+ ::end_io_cache(&cache);
+ if (buffer)
my_free(buffer);
- error=1;
- }
List_iterator<XML_TAG> xmlit(taglist);
XML_TAG *t;
while ((t= xmlit++))