enterprise-support team mailing list archive
-
enterprise-support team
-
Mailing list archive
-
Message #02978
[Bug 1265155] [NEW] create_main_connection use detected_server before setting it
Public bug reported:
Hi,
It's my first usage of launchpad, and i hope to not make a mistake by
using bug instead blueprint or anything else. Let me now if needed and
please excuse my bad english.
In 0.5.2 and 0.6.0 we can see in mydumper.c (MYSQL
*create_main_connection()) that :
----------------
if ((detected_server == SERVER_TYPE_MYSQL) && mysql_query(conn, "SET SESSION wait_timeout = 2147483")){
g_warning("Failed to increase wait_timeout: %s", mysql_error(conn));
}
if ((detected_server == SERVER_TYPE_MYSQL) && mysql_query(conn, "SET SESSION net_write_timeout = 2147483")){
g_warning("Failed to increase net_write_timeout: %s", mysql_error(conn));
}
detected_server= detect_server(conn);
----------------
As SERVER_TYPE_MYSQL is declared as 1 :
enum server_type { SERVER_TYPE_UNKNOWN, SERVER_TYPE_MYSQL, SERVER_TYPE_DRIZZLE };
the two first conditions should never match, and may the "
detected_server= detect_server(conn);" should be put first.
Thanks for your attention.
** Affects: mydumper
Importance: Undecided
Status: New
** Patch added: "mydumper.c__detect_server_first.diff"
https://bugs.launchpad.net/bugs/1265155/+attachment/3938159/+files/mydumper.c__detect_server_first.diff
--
You received this bug notification because you are a member of Ubuntu
Server/Client Support Team, which is subscribed to MySQL.
Matching subscriptions: Ubuntu Server/Client Support Team
https://bugs.launchpad.net/bugs/1265155
Title:
create_main_connection use detected_server before setting it
To manage notifications about this bug go to:
https://bugs.launchpad.net/mydumper/+bug/1265155/+subscriptions
Follow ups
References