ha_archive.cc:
Memory was used after it has been alreay freed. This led to server crash on FreeBSD. sql/examples/ha_archive.cc: Memory was used after it has been alreay freed. This led to server crash on FreeBSD.
This commit is contained in:
parent
8ce9725e53
commit
4e95ea7b6e
@ -188,9 +188,9 @@ static int free_share(ARCHIVE_SHARE *share)
|
|||||||
hash_delete(&archive_open_tables, (byte*) share);
|
hash_delete(&archive_open_tables, (byte*) share);
|
||||||
thr_lock_delete(&share->lock);
|
thr_lock_delete(&share->lock);
|
||||||
pthread_mutex_destroy(&share->mutex);
|
pthread_mutex_destroy(&share->mutex);
|
||||||
my_free((gptr) share, MYF(0));
|
|
||||||
if (gzclose(share->archive_write) == Z_ERRNO)
|
if (gzclose(share->archive_write) == Z_ERRNO)
|
||||||
rc= -1;
|
rc= -1;
|
||||||
|
my_free((gptr) share, MYF(0));
|
||||||
}
|
}
|
||||||
pthread_mutex_unlock(&archive_mutex);
|
pthread_mutex_unlock(&archive_mutex);
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user