leaks using MySQL C Api
Agreed, I am not calling mysql_store_result(). I attempted to add
my_free() but the function does not seem to exist, it is also not listed
in the API docs for the c api. As such it still seems that there should
be no leak, but yet I do get one. Thanks for the idea
Agreed, I am not calling mysql_store_result(). I attempted to add
my_free() but the function does not seem to exist, it is also not listed
in the API docs for the c api. As such it still seems that there should
be no leak, but yet I do get one. Thanks for the idea anyway Chris,
maybe you can
Hi!
You're looking for the function my_free(). Enjoy!
Regards,
Chris
John McCaskey wrote:
I have the following code:
//try the mysql connection
mysql_init(mysql_connection);
if(!mysql_real_connect(mysql_connection, db_host, db_user, db_pass,
db_db, 0, NULL, 0)) {
Hey wait a minute. Where did you get the my_free(), may be you are
trying to say mysql_free(), but then that is used only if result set is
used/called.
But the code does not show any result set call. ie. mysql_use_result()
or mysql_store_result().
So, the question now, how come there is a
I have the following code:
//try the mysql connection
mysql_init(mysql_connection);
if(!mysql_real_connect(mysql_connection, db_host, db_user, db_pass,
db_db, 0, NULL, 0)) {
flockfile(stderr);
fprintf(stderr, %s: Failed to connect to