mirror of
https://github.com/MariaDB/server.git
synced 2025-07-30 16:24:05 +03:00
Removed copying of parameters as this leads to memory leaks in embedded server.
Fixed 'not initialized' memory error.
This commit is contained in:
@ -37,7 +37,6 @@
|
||||
#include <mysys_err.h>
|
||||
#include <assert.h>
|
||||
|
||||
extern struct rand_struct sql_rand;
|
||||
|
||||
/*****************************************************************************
|
||||
** Instansiate templates
|
||||
@ -159,7 +158,7 @@ THD::THD():user_time(0),fatal_error(0),last_insert_id_used(0),
|
||||
pthread_mutex_lock(&LOCK_thread_count);
|
||||
ulong tmp=(ulong) (rnd(&sql_rand) * 3000000);
|
||||
pthread_mutex_unlock(&LOCK_thread_count);
|
||||
randominit(&rand, tmp + (ulong) start_time, tmp + (ulong) thread_id);
|
||||
randominit(&rand, tmp + (ulong) &rand, tmp + (ulong) ::query_id);
|
||||
}
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user