- set mysql reconnect to on. resolves #1240
git-svn-id: svn://svn.lighttpd.net/lighttpd/branches/lighttpd-1.4.x@1919 152afb58-edef-0310-8abb-c4023f1b3aa9svn/tags/lighttpd-1.4.17
parent
e8abdbf94e
commit
6eccc7abd6
|
@ -252,6 +252,11 @@ SERVER_FUNC(mod_mysql_vhost_set_defaults) {
|
|||
|
||||
return HANDLER_ERROR;
|
||||
}
|
||||
|
||||
/* in mysql versions above 5.0.3 the reconnect flag is off by default */
|
||||
my_bool reconnect = 1;
|
||||
mysql_options(s->mysql, MYSQL_OPT_RECONNECT, &reconnect);
|
||||
|
||||
#define FOO(x) (s->x->used ? s->x->ptr : NULL)
|
||||
|
||||
if (!mysql_real_connect(s->mysql, FOO(hostname), FOO(myuser), FOO(mypass),
|
||||
|
|
Loading…
Reference in New Issue